Skip to main content

A smart CLI tool to clean and update requirements.txt by fetching the latest versions from PyPI.

Project description

update-reqs 🚀

A smart CLI tool to clean and update your requirements.txt by fetching the latest package versions from PyPI.

✨ Features

Remove version numbers from requirements.txt (clean mode).
🚧 Fetch and update to the latest package versions from PyPI.
🔜 Preserve comments and structure in the requirements file.
🔜 Fast batch requests to PyPI for improved performance (In Progress).
🔜 Dry-run mode to preview changes before applying (Coming Soon).
🔜 Backup option before modifying requirements.txt (Coming Soon).

📦 Installation

pip install update-reqs

🚀 Usage

Basic Commands

Command Description
update-reqs clean --file requirements.txt Removes all version numbers from the file.
update-reqs update --file requirements.txt Updates all packages to the latest versions.
update-reqs update --file path/to/requirements.txt Updates a specific requirements file.
update-reqs --help Displays help and usage information.

📌 Feature Checklist

Feature Status
Remove version numbers ✅ Done
Fetch latest versions 🚧 In Progress
Preserve comments and formatting 🔜 Coming Soon
Parallelized requests for speed 🔜 Coming Soon
Dry-run mode (preview updates) 🔜 Coming Soon
Backup before modifying file 🔜 Coming Soon

🔥 How It Works

  1. Reads requirements.txt and extracts package names.
  2. Fetches the latest version of each package from PyPI.
  3. Updates the file while keeping comments and spacing intact.
  4. Writes back the updated requirements.txt.

🤝 Contributing

Want to help improve update-reqs? Follow these steps:

  1. Fork the repo.
  2. Clone your fork:
    git clone https://github.com/your-username/update-reqs.git
    cd update-reqs
    
  3. Install dependencies:
    pip install -r requirements.txt
    
  4. Create a new branch:
    git checkout -b feature-name
    
  5. Submit a Pull Request! 🚀

📜 License

This project is licensed under the MIT License.

🔹 Happy Coding!

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

update_reqs-1.1.0.tar.gz (3.8 kB view details)

Uploaded Source

Built Distribution

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

update_reqs-1.1.0-py3-none-any.whl (4.4 kB view details)

Uploaded Python 3

File details

Details for the file update_reqs-1.1.0.tar.gz.

File metadata

  • Download URL: update_reqs-1.1.0.tar.gz
  • Upload date:
  • Size: 3.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for update_reqs-1.1.0.tar.gz
Algorithm Hash digest
SHA256 d06a335af80efe0e1e50b787189f14afea747a5b845fae824c42dad592f0109a
MD5 7c575b19df373f2e2eda84e8a7d9c007
BLAKE2b-256 f32b332c4fb80cb19034fa2bee91da5b5eb911a7da78b29a4c2218b6a37e2b60

See more details on using hashes here.

File details

Details for the file update_reqs-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: update_reqs-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 4.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for update_reqs-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4d2d8810b3e01821865dcb4d4ab4b8deef1260e47cd2b78fd29aef0bb0d02344
MD5 734753a336eef83b2356be66748f883f
BLAKE2b-256 392728db4cd46ec2ebacc9199aab3f3a7128b9d6869ed96432a69d1f36cf7cc3

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