Skip to main content

A tool to install and save clean package dependencies

Project description

SavePip

A tool to intelligently install and save clean package dependencies for both pip and conda environments.

Installation

pip install savepip

Usage

# Install packages with pip
savepip install pandas numpy

# Install packages with conda
savepip -m conda numpy pandas

# Save current environment
savepip save

# Upgrade packages
savepip -u requests pandas

# Save to custom file
savepip -o custom_requirements.txt requests pandas

Features

  • Smart Dependency Management: Tracks installed packages in a memory file for future reference
  • Requirements.txt Preservation: Maintains packages in requirements.txt even if not in memory
  • Selective Package Tracking: Only includes packages explicitly installed with savepip or already in requirements.txt
  • Synchronization: Automatically syncs memory with requirements.txt content
  • Clean Output: Removes build hashes, development versions, and unnecessary information
  • Package Manager Support: Works with both pip and conda environments
  • Alphabetical Sorting: Dependencies are sorted alphabetically for readability

How It Works

SavePip maintains a memory of installed packages in .savepip/memory.json and uses this to:

  1. Track packages explicitly installed with savepip
  2. Preserve packages already in requirements.txt
  3. Update package versions when they change
  4. Generate clean requirements files

Unlike pip freeze, savepip only includes packages you've specifically chosen to track, avoiding bloated requirements files with unnecessary dependencies.

Category Management

SavePip supports organizing packages into categories, allowing you to manage different sets of dependencies for different purposes:

# Create a new category
savepip mk-category dev

# Switch to a category
savepip use-category dev

# Show current category
savepip cur-category

# List all categories
savepip ls-category

# Install packages to the current category
savepip install pytest coverage

# Save dependencies from specific categories
savepip save --categories dev,prod

This feature is useful for managing different types of dependencies (e.g., development, production, testing) within the same project.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contribution

We welcome contributions! Feel free to submit issues or pull requests.

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

savepip-0.2.0.tar.gz (9.2 kB view details)

Uploaded Source

Built Distribution

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

savepip-0.2.0-py3-none-any.whl (9.2 kB view details)

Uploaded Python 3

File details

Details for the file savepip-0.2.0.tar.gz.

File metadata

  • Download URL: savepip-0.2.0.tar.gz
  • Upload date:
  • Size: 9.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for savepip-0.2.0.tar.gz
Algorithm Hash digest
SHA256 dcd62d2a6067179a5c2cb48e2b4f30212700cef1a69ddcb86f47fbec93df257d
MD5 5aa24094c17f1b36b3fa839d02eb9e66
BLAKE2b-256 e0ea97c4a79ea1896b3c4961e44cbb1c6240d15057bb982f7a5e06b81d777e05

See more details on using hashes here.

Provenance

The following attestation bundles were made for savepip-0.2.0.tar.gz:

Publisher: python-publish.yml on Aeidle/savepip

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file savepip-0.2.0-py3-none-any.whl.

File metadata

  • Download URL: savepip-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 9.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for savepip-0.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 7a0c3b5b58dea0b73e98e424c934b5199326e3dbc58c54ee2e4a697dda5100c5
MD5 c377693e722bd4e5aebd3ea0bd6d04ee
BLAKE2b-256 f24df19da6e59e19d8b5948a73505a5f619912c025b339af2ef05059f42ce879

See more details on using hashes here.

Provenance

The following attestation bundles were made for savepip-0.2.0-py3-none-any.whl:

Publisher: python-publish.yml on Aeidle/savepip

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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