Requirements management tool.
Project description
Pundle
=======
Pundle is bunder-like replacement of virtualenv for developers and works great with pyenv.
It is not recommended to use Pundle for deployment (it was created for different purpose)
and currently only works with PyPI packages. Git, SVN and other package sources will be added later.
For now works only with PyPI packages.
Git, svn and others support planned.
Prerequisites
-------------
- I recommend using pyenv
- requires setuptools
- requires pip
Commands
--------
`pundle [install]` will install files from frozen.txt file and reveal
new requirements if something is not frozen yet.
`pundle upgrade` will recreate frozen.txt from requirements.txt.
`pundle fixate` installs site customization for current python.
`pundle exec cmd [args]` executes entry point from one of the installed packages.
`pundle entry_points` prints entry points from all packages.
`pundle edit [package]` returns path to package directory.
How to play with it
-------------------
Simple with usercustomize.py:
git clone git@github.com:Deepwalker/pundler.git
python pundler/pundle.py fixate
cd testproject
python -m pundle upgrade
Pundle will create directory `~/.pundledir` and file `frozen.txt`.
Or you can make ``alias pundle='python /full/path/to/pundle/pundle.py'`` and use it.
And add ``/full/path/to/pundle`` to your ``PYTHONPATH``.
But you will need to manual load dependencies in your project start script, like this:
import pundle
parser_kw = pundle.create_parser_parameters()
suite = pundle.Parser(**parser_kw).create_suite()
if suite.need_freeze():
raise Exception('%s file is outdated' % suite.parser.frozen_file)
if suite.need_install():
raise Exception('Some dependencies not installed')
suite.activate_all()
DONE
----
- install according to frozen.txt
- on update rewrite frozen.txt
- on launch check if frozen.txt is in touch with requirements.txt
- search through hierarchy upward
- tie packages to python version.
- package scripts
- upgrade must lookup PyPI for new version
- in install mode if requirement is not frozen, then install latest package from PyPI. Else install frozen version.
in 'upgrade package' - upgrade selected package and dependencies, if needed.
in 'upgrade' - upgrade all packages.
TODO
----
- ! write source of requirement (requirements.txt or other package) to frozen.txt then we can check unneeded requirements without installed packages
- ! add vcs support
- add environments support, aka development, testing.
Maybe generate frozen.txt only for pip and use more rich structure for itself?
And put only production packages to frozen.txt, and track all, development and others in frozen.toml?
- ? tie packages only where we need this (C extensions, py2 without __pycache__ support)
- ? bundle distlib (now using one from pip)
- ? bundle pkg_resources (now using one from setuptools)
=======
Pundle is bunder-like replacement of virtualenv for developers and works great with pyenv.
It is not recommended to use Pundle for deployment (it was created for different purpose)
and currently only works with PyPI packages. Git, SVN and other package sources will be added later.
For now works only with PyPI packages.
Git, svn and others support planned.
Prerequisites
-------------
- I recommend using pyenv
- requires setuptools
- requires pip
Commands
--------
`pundle [install]` will install files from frozen.txt file and reveal
new requirements if something is not frozen yet.
`pundle upgrade` will recreate frozen.txt from requirements.txt.
`pundle fixate` installs site customization for current python.
`pundle exec cmd [args]` executes entry point from one of the installed packages.
`pundle entry_points` prints entry points from all packages.
`pundle edit [package]` returns path to package directory.
How to play with it
-------------------
Simple with usercustomize.py:
git clone git@github.com:Deepwalker/pundler.git
python pundler/pundle.py fixate
cd testproject
python -m pundle upgrade
Pundle will create directory `~/.pundledir` and file `frozen.txt`.
Or you can make ``alias pundle='python /full/path/to/pundle/pundle.py'`` and use it.
And add ``/full/path/to/pundle`` to your ``PYTHONPATH``.
But you will need to manual load dependencies in your project start script, like this:
import pundle
parser_kw = pundle.create_parser_parameters()
suite = pundle.Parser(**parser_kw).create_suite()
if suite.need_freeze():
raise Exception('%s file is outdated' % suite.parser.frozen_file)
if suite.need_install():
raise Exception('Some dependencies not installed')
suite.activate_all()
DONE
----
- install according to frozen.txt
- on update rewrite frozen.txt
- on launch check if frozen.txt is in touch with requirements.txt
- search through hierarchy upward
- tie packages to python version.
- package scripts
- upgrade must lookup PyPI for new version
- in install mode if requirement is not frozen, then install latest package from PyPI. Else install frozen version.
in 'upgrade package' - upgrade selected package and dependencies, if needed.
in 'upgrade' - upgrade all packages.
TODO
----
- ! write source of requirement (requirements.txt or other package) to frozen.txt then we can check unneeded requirements without installed packages
- ! add vcs support
- add environments support, aka development, testing.
Maybe generate frozen.txt only for pip and use more rich structure for itself?
And put only production packages to frozen.txt, and track all, development and others in frozen.toml?
- ? tie packages only where we need this (C extensions, py2 without __pycache__ support)
- ? bundle distlib (now using one from pip)
- ? bundle pkg_resources (now using one from setuptools)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pundle-0.1.tar.gz
(6.5 kB
view details)
File details
Details for the file pundle-0.1.tar.gz
.
File metadata
- Download URL: pundle-0.1.tar.gz
- Upload date:
- Size: 6.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4653d70474844d53a3d87acfb0fc23ad9a5260144d6b52566dd1227978b2f578 |
|
MD5 | d42888efe11131e8b4be593866f77e07 |
|
BLAKE2b-256 | 88168f97a4a2e4940ad5847bb06d9bbcc7b7eadeaee1b41d2c4d79d7972f6d7f |