Skip to main content

A wrapper for pip download in offline scenario.

Project description

pip-download: A wrapper useful in offline scenario

简体中文

pip-download is a tool which can be used to download python projects and their dependencies listed on pypi's download files page. If you run the pip-download command to download one project on a Linux platform, packages end with .whl and can be directly installed on a Windows and a macOS platform will also be downloaded. In that way, you can use these downloaded packages to serve for a minimal pypi sever(like pypiserver ) on your company internal network.

At first, it uses pip download xxx command to download packages of the project xxx to a temp dir. Then it unpacks these downloaded packages' name and version to download all packages of the project xxx. These downloaded packages include packages end with .whl built on the Linux, Windows, macOS platform and the source packages end with .tar.gz or .zip .

Installation

pip-download is distributed on PyPI and is available on Linux/macOS and Windows and supports Python 3.6+. You can simply install pip-download as below:

$ pip install pip-download

However, it's a better choice to use a virtual environment:

$ python -m venv venv
# On Windows:
$ .\venv\Scripts\activate
# On Linux:
$ source venv/bin/activate
$ pip install pip-download

virtualenv is also a good choice.

Usage

After installation, you can use pip-download to download python projects and its dependencies.

$ pip-download flask
$ pip-download -r requirements.txt
$ pip-download hatch -d /tmp/
$ pip-dwonload -py cp37 ujson
$ pip-dwonload -py cp37 -p win_amd64 ujson

Also, you can put your common options in the config file, python_versions and platform_tags are supported now:

$ pip-download --show-config
/some-path-to/settings.json

$ vim /some-path-to/settings.json
{
    "python-versions": ["cp37"],
    "platform-tags": ["win_amd64"]
}

$ vim /some-path-to/settings.json
{
    "python-versions": ["cp37", "cp36"],
    "platform-tags": ["win_amd64", "manylinux"]
}

For more usage, use pip-download --help.

Credits

  • All the people who work on Click
  • All the people involved in the project hatch

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

pip-download-0.3.1.tar.gz (11.6 kB view details)

Uploaded Source

Built Distribution

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

pip_download-0.3.1-py3-none-any.whl (13.9 kB view details)

Uploaded Python 3

File details

Details for the file pip-download-0.3.1.tar.gz.

File metadata

  • Download URL: pip-download-0.3.1.tar.gz
  • Upload date:
  • Size: 11.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5

File hashes

Hashes for pip-download-0.3.1.tar.gz
Algorithm Hash digest
SHA256 e6fd82ae8e09cd8d4efa77dc28ebf179513acd7c2da3fe67ed5a700decf735d5
MD5 2c6e5280631d17f6194a3b572eb29f4f
BLAKE2b-256 435e2133142e5fafddf4d2b1b37068ac00191f4e6c302b921eb99aa5c6f29e01

See more details on using hashes here.

File details

Details for the file pip_download-0.3.1-py3-none-any.whl.

File metadata

  • Download URL: pip_download-0.3.1-py3-none-any.whl
  • Upload date:
  • Size: 13.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/47.1.0 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5

File hashes

Hashes for pip_download-0.3.1-py3-none-any.whl
Algorithm Hash digest
SHA256 50e28b587fbf22bada395938a43472b47a496470b44f9b098230e9e15f148965
MD5 ea7aedc6d62200ca2d974b2f888a1cc6
BLAKE2b-256 2f3da41aa2622da6198288ca78218bed1bbede55393c7a19d63619d866f4d065

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