Skip to main content

Module which provides 'yum provides' functionality across many package managers

Project description

whichprovides

Package manager agnostic support for "yum whichprovides" which maps a file back to its providing package. This is useful for generating a package URL (PURL) identifier.

You can install the package from PyPI like so:

$ python -m pip install whichprovides

You can also "splat" the module into your own projects:

$ git clone https://codeberg.org/sethmlarson/whichprovides
$ cp whichprovides/src/whichprovides/__init__.py ./whichprovides.py

Then use the whichprovides() API inside of Python code:

>>> import whichprovides
>>> whichprovides.whichprovides("/usr/lib/x86_64-linux-gnu/libssl3.so")

ProvidedBy(
  package_type='deb',
  distro='ubuntu',
  package_name='libnss3',
  package_version='2:3.98-0ubuntu0.22.04.2'
)

The functionality is also accessible from the command line:

$ python -m pip install whichprovides
$ python -m whichprovides /usr/lib/x86_64-linux-gnu/libssl3.so 

pkg:deb/ubuntu/libnss3@2:3.98-0ubuntu0.22.04.2

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

whichprovides-0.3.0.tar.gz (6.7 kB view details)

Uploaded Source

Built Distribution

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

whichprovides-0.3.0-py3-none-any.whl (4.8 kB view details)

Uploaded Python 3

File details

Details for the file whichprovides-0.3.0.tar.gz.

File metadata

  • Download URL: whichprovides-0.3.0.tar.gz
  • Upload date:
  • Size: 6.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.4

File hashes

Hashes for whichprovides-0.3.0.tar.gz
Algorithm Hash digest
SHA256 cbe47e9e1947de49f9634f4c9aa8b94d0fc71beb63c6bcc64f024bab5993cd28
MD5 534e574bed40f02b057010c75131f42c
BLAKE2b-256 fe3ee9d032c56a735431e979255da5fffc9537fc6f70d91ebe2833bf3b2ceae6

See more details on using hashes here.

File details

Details for the file whichprovides-0.3.0-py3-none-any.whl.

File metadata

  • Download URL: whichprovides-0.3.0-py3-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.4

File hashes

Hashes for whichprovides-0.3.0-py3-none-any.whl
Algorithm Hash digest
SHA256 927e72bcfe683a3b4104c698b15aa56d5c9a5301e05c7b7c8748052820778912
MD5 981d88e75635a6089e1fae17c5f32780
BLAKE2b-256 c3588431499a36ee33a70dbbc45108f4727082b3cbee2ed4beb79801bb36336f

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