Skip to main content

PyBuild is a build environment for Python that starts from the virtual environment upwards, must be installed on base system prior to running.

Project description

Build Status

PyBuild

Developed by Kyle Darling


Purpose

PyBuild was developed to aid in quick, robust, procedurally generated build environments where the user can develop scripts quick in setting up their Python environment to their needs. The difference between PyBuild and other build frameworks available in Python is that PyBuild focuses on outside packages that may not be available to pip install or build itself into an executable.

PyBuild relies heavily on the Environment class where initially it uses the Python interpreter used to run a PyBuild script as it's main environment, later this can change with the use of VirtualEnv where a virtual environment can be used instead, effectively swapping the environment to the virtual environment.

Basic Usage

PyBuild supports quick and easy installations of packages.

from pybuild import pip
from pybuild.environment import Environment

environment = Environment('pybuild_demo')
pip.install(environment, 'matplotlib>=1.0.0', 'numpy', 'virtualenv==16.6.0')

pybuild_demo would become the name of the virtual environment.

Developers may also use the with context in Python to use an environment.

from pybuild import pip
from pybuild.environment import environment
from pybuild.virtualenv import VirtualEnv

with Environment('pybuild_demo') as environment:
    Virtualenv(environment)
    pip.install(environment, 'matplotlib')

Virtual environments are deleted after completion.

The pip package inside PyBuild acts as a wrapper like most things do in PyBuild around the Python interpreter, accessing scripts as needed. This means that PyBuild supports additional arguments for installations and uninstallations.

from pybuild import pip
from pybuild.environment import Environment

with Environment('pybuild_demo') as environment:
    pip.install(environment, 'matplotlib', no_cache_dir=True)

no_cache_dir will be parsed and used as an argument to pip install.

Demonstration

Now that you understand how PyBuild works by using the Environment class and the general functionality of PyBuild has been demonstrated, how about a more advanced setup?

To Do

PyBuild is rather new project that always has module integration in mind when developing and with that there exists additional modules that should be added.

  • Common modules class for any class objects created to help guide users.
  • Registering external modules to PyBuild, dynamic module loading would be required.
  • Add more modules! The suite right now has been trimmed down to personal usage of the modules but other virtual environments, documentation, etc are always welcomed.
  • Add master demo.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pybuildme-0.3.4.tar.gz (16.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pybuildme-0.3.4-py3-none-any.whl (20.5 kB view details)

Uploaded Python 3

File details

Details for the file pybuildme-0.3.4.tar.gz.

File metadata

  • Download URL: pybuildme-0.3.4.tar.gz
  • Upload date:
  • Size: 16.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.9

File hashes

Hashes for pybuildme-0.3.4.tar.gz
Algorithm Hash digest
SHA256 33ac691b8a50a9035b3c5a5819bb96e6cbf78beb605bae558b8e74343b2894ef
MD5 0725726171c391225da84e302439d799
BLAKE2b-256 8bc4944e1d2f916b38cffd2eec188e7b43f1d82d57635b204b4b7c9ced7e67d7

See more details on using hashes here.

File details

Details for the file pybuildme-0.3.4-py3-none-any.whl.

File metadata

  • Download URL: pybuildme-0.3.4-py3-none-any.whl
  • Upload date:
  • Size: 20.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.8.9

File hashes

Hashes for pybuildme-0.3.4-py3-none-any.whl
Algorithm Hash digest
SHA256 9e245fcd917c71ee9fc6b44fb227581f8933bd42338e5b2ecfea86859b88e419
MD5 1cd20087ad77efdaa531b7537ca1c131
BLAKE2b-256 23e1cf7b10f99ba5a2b98cb050dc72a0595af6ec1d0e16b9f6c072b94e0b4148

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page