Skip to content

A versatile tool for effortlessly updating pip requirements while keeping your requirements.txt file in sync with the latest package versions. No more tedious manual package-by-package upgrades; this tool handles it for you and updates your requirements.txt file accordingly.

License

Notifications You must be signed in to change notification settings

thisisazeez/pip-ascent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pip-ascent

A versatile tool for effortlessly updating pip requirements while keeping your requirements.txt file in sync with the latest package versions. No more tedious manual package-by-package upgrades; this tool handles it for you and updates your requirements.txt file accordingly.

Purpose

This command-line tool allows you to interactively (or non-interactively) upgrade packages from your requirements file. It also enables you to update the pinned version in your requirements file(s). If no requirements are specified, the tool will attempt to detect the requirements file(s) in the current directory.

Installation

pip install pip-ascent

Note: This package installs the following dependencies: 'docopt', 'packaging', 'requests', 'terminaltables', 'colorclass'. To avoid installing these dependencies in your project, you can install pip-ascent in your system rather than your virtual environment. If you install it in your system and need to upgrade it, run pip install -U pip-ascent.

Usage

pip-ascent [<requirements_file>] ... [--prerelease] [-pk=<package>...] [--dry-run] [--check-greater-equal] [--skip-virtualenv-check] [--skip-package-installation] [--use-default-index]

Activate your virtual environment (important because it will also install the new versions of upgraded packages in the current virtual environment).

Change directory into your project. Then:

$ pip-ascent

Arguments:

  • requirements_file: Specifies the requirement file or uses a wildcard path to multiple files.
  • --prerelease: Includes prerelease versions for upgrades when querying PyPI repositories.
  • -pk <package>: Pre-selects packages for an upgrade, bypassing any prompts. You can also utilize regular expressions to filter packages for upgrading.
  • --dry-run: Simulates the upgrade but does not perform the actual upgrade.
  • --check-greater-equal: Also checks packages with minimum version pinning (package>=version).
  • --skip-package-installation: Upgrades the version in requirement files only; it does not install the new package.
  • --skip-virtualenv-check: Disables virtual environment check, permitting the installation of new packages outside the virtual environment.
  • --use-default-index: Skips searching for a custom index URL in pip configuration file(s).

Examples:

  • pip-ascent: Automatically discovers the requirements file.

  • pip-ascent requirements.txt

  • pip-ascent requirements/dev.txt requirements/production.txt

  • pip-ascent requirements.txt -pk django -pk celery

  • pip-ascent requirements.txt -pk all

  • pip-ascent requirements.txt --dry-run: Runs everything as a simulation (does not perform the actual upgrade)

💖 Like this project?

Leave a ⭐ if you find this project cool.

Share with the world

👨‍💻 Author

Abdulazeez Sherif

Twitter

🍁 License

MIT

Note: This package is just starting out feel free to make contributions.

(back to top)

About

A versatile tool for effortlessly updating pip requirements while keeping your requirements.txt file in sync with the latest package versions. No more tedious manual package-by-package upgrades; this tool handles it for you and updates your requirements.txt file accordingly.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Languages