Pypm is a python package manager for projects using Python 3 and above. This library is similar to npm. This command line tool works just like npm and should mirror its features.
Yet another Python tool for your PATH
. If you're fluent in Flint or Poetry, give this a try. See areas of improvements? Let me know with a PR!
PyPM currently uses setup.cfg
as the configuration file. This will be changed to adopt the .toml
configuration file approach.
This project intends to introduce another project management tool to the Python community, plus its super light-weight.
requires Python 3.6 or above
PyPI
pip install pypm2
Locally
git clone https://github.com/ableinc/pypm
cd pypm
pip install --editable .
Visit PyPi: PyPi for Pyenv
PyPM works just like npm. You are granted the same operations such as, init, install, uninstall, update, start, and run. Run:
pypm --help
init Generate a brand new package.json file from information in your requirements.txt and setup.py.
pypm init
run Run a predefined scripts from the 'scripts' section of your package.json.
pypm run tests
start Run the start script.
pypm start
install 1 Install all or specific packages. Using 'install' as a standalone, it will install all dependencies listed in your package.json (if exists).
pypm install
or
pypm install package1 package2
uninstall 1 Uninstall all or specific packages. Using 'uninstall' as a standalone, it will uninstall all dependencies listed in your package.json (if exists).
pypm uninstall
or
pypm uninstall package1 package2
update 1 Update all or specific packages. Using 'update' as a standalone, it will update all dependencies listed in your package.json (if exists).
pypm update
or
pypm update package1 package2
setup Instead of manually creating setup.py and setup.cfg files, you can add the same arguments under the 'setup' key in the package.json (refer to package.json), then run pypm setup to install your project locally.
pypm setup
Update setuptools, wheel, pip:
pypm setup True
Specify a version of python to use:
pypm setup --python python3.9
getreqs Generate the requirments.txt file based on your (virtual) environment.
pypm getreqs
1 Any arguments that pip or npm allow can be combined into these command line arguments. Initiated by adding --arguments option. Example:
pypm --arguments --no-cache-dir install pydotenvs
The above example will install the library pydotenvs via PyPI using Pip's built in --no-cache-dir command.
If you have multiple arguments to append to a command you can seperate them by commas. For example:
pypm --arguments --no-cache,--verbose,--logs,~/Downloads install pydotenvs
Documentation is on-going, so refer to examples above for now.
Unfortunately someone beat me to the name pypm. Note that when you use pip install be sure to include the 2. This would normally be an issue if you imported this package, but it's a command line tool
When generating the setup.py & setup.cfg files for development mode installation pip, setuptools and wheel may need to be updated. Follow the instructions above to update alongside setup functionality.
January 2023
August 2022
pypm init
can now generate the requirements.txt file by pypm command (pypm getreqs)pypm setup
. By default it will use python3.June 2021
April 2021
September 2020
August 2020