Skip to main content

this is an unofficial pypi distribution of the flatpak_pip_generator script

Project description

Flatpak PIP Generator

this is an unofficial pypi distribution of the flatpak_pip_generator script

upstream - https://github.com/flatpak/flatpak-builder-tools/tree/master/pip

Tool to automatically generate flatpak-builder manifest json from a pip package-name.

This requires requirements-parser which can be installed on your host with pip3 install --user requirements-parser.

Usage

flatpak-pip-generator --runtime='org.freedesktop.Sdk//22.08' foo which generates python3-foo.json and can be included in a manifest like:

"modules": [
  "python3-foo.json",
  {
    "name": "other-modules"
  }
]

You can also list multiple packages in single command:

flatpak-pip-generator --runtime='org.freedesktop.Sdk//22.08' foo\>=1.0.0,\<2.0.0 bar

If your project contains a requirements.txt file with all the project dependencies, you can use

flatpak-pip-generator --runtime='org.freedesktop.Sdk//22.08' --requirements-file='/the/path/to/requirements.txt' --output pypi-dependencies

You can use that in your manifest like

"modules": [
  "pypi-dependencies.json",
  {
    "name": "other-modules"
  }
]

Options

  • --python2: Build with Python 2. Note that you will have to build the Python 2 shared-module as it is not in any runtime.
  • --build-isolation: Enable build isolation with pip (recommended but not always work).
  • --cleanup=(scripts|all): Add cleanup to the manifest. This is used when the packages installed are only used at build time.
  • --build-only: Alias to --cleanup=all.
  • --requirements-file=, -r: Reads the list of packages from requirements.txt file.
  • --ignore-pkg=: Ignore a specific package name in a requirements-file, otherwise ignored.
  • --checker-data: This adds x-checker-data to modules so you will be notified when new releases happen. See flatpak-external-data-checker for more details.
  • --runtime=: Runs pip inside of a specific Flatpak runtime instead of on your host. Highly recommended for reproducability and portability. Examples would be org.freedesktop.Sdk//22.08 or org.gnome.Sdk/aarch64/43.
  • --ignore-errors=: Allow the generation of empty or otherwise broken files when downloading packages fails.
  • --ignore-installed=: Comma-separated list of package names for which pip should ignore already installed packages. Useful when the package is installed in the SDK but not in the runtime.
  • --output=: Sets an output file.
  • --yaml: Outputs a YAML file.

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

flatpak_pip_generator-24.0.0.tar.gz (7.4 kB view details)

Uploaded Source

Built Distribution

flatpak_pip_generator-24.0.0-py3-none-any.whl (7.9 kB view details)

Uploaded Python 3

File details

Details for the file flatpak_pip_generator-24.0.0.tar.gz.

File metadata

File hashes

Hashes for flatpak_pip_generator-24.0.0.tar.gz
Algorithm Hash digest
SHA256 cfe72c05b8d13084bd2aaabc107384924f1bcd5132832162b2a3dc0d2d2bda34
MD5 2cbbcb729fc5faf6d0cca5b47121ffe3
BLAKE2b-256 cad46247fed2eff9f2718e13617a4d8421d2e6ec2d4aa01fe5d8272204c09e7f

See more details on using hashes here.

File details

Details for the file flatpak_pip_generator-24.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for flatpak_pip_generator-24.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 9ce8dac77eb2b6423af32ed44987204cf348f2e0e76400c1ba59304c124f8b19
MD5 1e837c162897bb440df05ed9ce6314f6
BLAKE2b-256 0e596b6284e39c8d38129f41a6d5dc8ebd88a557c9400ee98a081ed195c94951

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