Automatically add and delete modules to requirements.txt installing them using pip.
Project description
REX | Automatically Update requirements.txt
REX allows for the automatic management of dependencies in requirements.txt
using pip as a package manager.
Benefits
-
Easy Setup: The installation process involves just two steps: installing the package using pip and setting it up using the provided script. That's it.
-
One-Command Setup: Set up a VirtualEnv-based project in a single command. It creates a virtual environment and installs to-requirements.txt automatically.
-
Customizable: Customize it as you prefer: use it only in Git repositories, allow or disallow automated
requirements.txt
file creation, enable or disable the package itself. -
User-Friendly: After installation and setup, there are no additional conditions to use. Simply install, uninstall, or upgrade packages using pip as usual.
-
Always in Sync: With to-requirements.txt, the project's
requirements.txt
will always stay in sync with packages installed via pip.
Installation
To install the package, run the following command:
pip install rex
To enable all available functionality, add the following lines to your .bashrc
, .zshrc
, or other .*rc
file:
rex alias
or just paste this lines to your .bashrc
, .zshrc
, or other .*rc
file:
alias rt=". rt"
alias requirements-txt=". requirements-txt"
alias rex=". rex"
This enables sourced mode of the CLI execution and allows the CLI to activate or deactivate your virtual environment if required.
Setup Project
To set up a VirtualEnv-based project, simply type:
rex init
Or, achieve the same effect more easily with aliases:
rex i
Note: The changes made to pip scripts will not affect the ordinary pip workflow after uninstalling to-requirements.txt.
Aliases
There are a few aliases available to use instead of rex
command:
requirements-txt
- legacy command.rt
- legacy command shortened.
Documentation
For detailed documentation, visit requirements-txt.readthedocs.io.
Contributing
See CONTRIBUTING.md for contribution guidelines.
License
This project is licensed under the MIT License.
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
Built Distribution
File details
Details for the file rex-2.0.14.tar.gz
.
File metadata
- Download URL: rex-2.0.14.tar.gz
- Upload date:
- Size: 22.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.22
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
6d75a92254efe86c344db62a0737542a65c9ce9c263ee0134865d081bc26461a
|
|
MD5 |
d190bd0575c82cc135e582f08ce8a1c5
|
|
BLAKE2b-256 |
582d1a9033dba031b7109945c923ebc65b4578e5338ae8764adc32a7c56db6f5
|
File details
Details for the file rex-2.0.14-py3-none-any.whl
.
File metadata
- Download URL: rex-2.0.14-py3-none-any.whl
- Upload date:
- Size: 37.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.22
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
31383891f5c57e57a55bcfa34d7537ce5ce3b1bb4f531bf980530d50bfa574f2
|
|
MD5 |
997bcbe0070409f7e3abe54d2e6d2807
|
|
BLAKE2b-256 |
bc22098dd21dc8ac69c81ed013e7bd4ea3a3b85c6987921251dbf3171bafbd5b
|