Skip to main content

Automatically generate and apply patches to fix installed packages

Project description

patch-package

PyPI - Python Version PyPI

patch-package is a Python library to automatically create and apply patches from changes made in installed packages. It is heavily inspired by patch-package which is the equivalent for Node packages.

Features

  • Compatible with Python 2.7 and Python 3.5+
  • Automatic code change detection between installed package and package source from pip
  • Prevent patching when version or code are mismatching
  • Automatic matching between import names and package names (e.g. yaml -> PyYAML) and fuzzy matching (e.g. request -> requests)

Usage

Install the library from PyPI

pip install patch-package

Make a change in one of your installed package and then generate the corresponding patch

patch-package <package-name>

Then when reinstalling the package you can apply back your patches

patch-package

All patches are contained in the patches/ folder so it can be commited to git and reapply whenever you want

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

patch_package-0.1.2.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

patch_package-0.1.2-py2.py3-none-any.whl (3.7 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file patch_package-0.1.2.tar.gz.

File metadata

  • Download URL: patch_package-0.1.2.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.6 Linux/6.11.1-arch1-1

File hashes

Hashes for patch_package-0.1.2.tar.gz
Algorithm Hash digest
SHA256 3d1e7071da45659d630072cdc5669131368815859a09fb921986777f3718a0cf
MD5 04870c284051eb8124928ee14be90fe1
BLAKE2b-256 fced5f082137ecaf3b713e881dc575f37edd0da1b579afba7f22bc36a7699766

See more details on using hashes here.

File details

Details for the file patch_package-0.1.2-py2.py3-none-any.whl.

File metadata

  • Download URL: patch_package-0.1.2-py2.py3-none-any.whl
  • Upload date:
  • Size: 3.7 kB
  • Tags: Python 2, Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.12.6 Linux/6.11.1-arch1-1

File hashes

Hashes for patch_package-0.1.2-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 c7c3a014e0db79cf9b4dcc49e8e51ef816dbb33e8fd1c4380f0d53904836ed8a
MD5 42122b6fd6cb0ea3508d1501e91ae0c2
BLAKE2b-256 3033a1c61cddfb55780be4fd4967b472d726dd909a507d412b6f9dae9ba257bd

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page