Skip to main content

PyPI Build Status Coverage Status Documentation Status License

snake

shiv

shiv is a command line utility for building fully self-contained Python zipapps as outlined in PEP 441, but with all their dependencies included!

shiv's primary goal is making distributing Python applications fast & easy.

Full documentation can be found here.

how to

shiv has a few command line options of its own and accepts almost all options passable to pip install.

simple cli example

Creating an executable of pipenv with shiv:

$ shiv -c pipenv -o ~/bin/pipenv pipenv pew
$ ~/bin/pipenv --version
pipenv, version 2018.05.18
complex example involving a wheel cache

Creating an interactive executable with a downloaded wheel of boto:

$ python3 -m pip download boto
Collecting boto
  File was already downloaded /tmp/tmp.iklsO1qyd3/boto-2.48.0-py2.py3-none-any.whl
Successfully downloaded boto
$ shiv -o boto.pyz --find-links . --no-index boto
 shiv! 🔪
Collecting boto
Installing collected packages: boto
Successfully installed boto-2.48.0
 done
$ ./boto.pyz
Python 3.6.1 (default, Apr 19 2017, 21:58:41)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-4)] on linux
Type "help", "copyright", "credits" or "license" for more information.
(InteractiveConsole)
>>> import boto
>>>

installing

You can install shiv via pip / pypi

pip install shiv

You can even create a pyz of shiv using shiv!

python3 -m venv shiv
source shiv/bin/activate
pip install shiv
shiv -c shiv -o shiv shiv

developing

We'd love contributions! Getting bootstrapped to develop is easy:

git clone git@github.com:linkedin/shiv.git
cd shiv
python3 setup.py venv
. activate
python3 setup.py develop

Don't forget to run and write tests:

pip install tox
tox

gotchas

Zipapps created with shiv are not cross-compatible with other architectures. For example, a pyz file built on a Mac will only work on other Macs, likewise for RHEL, etc.

Zipapps created with shiv will extract themselves into ~/.shiv, unless overridden via SHIV_ROOT. If you create many utilities with shiv, you may want to ocassionally clean this directory.


acknowledgements

Similar projects:

Logo by Juliette Carvalho

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

shiv-0.0.25.tar.gz (14.4 kB view details)

Uploaded Source

Built Distribution

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

shiv-0.0.25-py3-none-any.whl (11.9 kB view details)

Uploaded Python 3

File details

Details for the file shiv-0.0.25.tar.gz.

File metadata

  • Download URL: shiv-0.0.25.tar.gz
  • Upload date:
  • Size: 14.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for shiv-0.0.25.tar.gz
Algorithm Hash digest
SHA256 d767a24c93e99a0b8d44a61213eabb3ea94ee226fb730d930d2b8ea7beb7d8ee
MD5 757bc17796548b0e980a3c0d95fb2f22
BLAKE2b-256 54c0b164775034edb0cbf03769847029c69c1d36e6cb778448a5ec6108bc52ba

See more details on using hashes here.

File details

Details for the file shiv-0.0.25-py3-none-any.whl.

File metadata

File hashes

Hashes for shiv-0.0.25-py3-none-any.whl
Algorithm Hash digest
SHA256 a44abd1842b7c4992a5297ea272ce5e3dbea40e9efdcda095daa6db6b828e8a5
MD5 758be169b3142829c1490eeb59357e5c
BLAKE2b-256 d368de2aa116322eef0f6fe5cb5070b2a9be11c49880846f587decddcf37804d

See more details on using hashes here.

Release history Release notifications | RSS feed

1.0.8

2 files

1.0.7

2 files

1.0.6

2 files

1.0.5

2 files

1.0.4

2 files

1.0.3

2 files

1.0.2

2 files

1.0.1

2 files

1.0.0

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.0

2 files

0.3.1

2 files

0.3.0

2 files

0.2.0

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

0.0.52

2 files

0.0.51

2 files

0.0.50

2 files

0.0.48

2 files

0.0.47

3 files

0.0.46

2 files

0.0.45

2 files

0.0.44

2 files

0.0.43

2 files

0.0.41

2 files

0.0.40

2 files

0.0.39

2 files

0.0.38

2 files

0.0.37

2 files

0.0.36

2 files

0.0.35

2 files

0.0.34

2 files

0.0.33

2 files

0.0.32

2 files

0.0.31

2 files

0.0.30

2 files

0.0.29

2 files

0.0.28

2 files

0.0.27

2 files

0.0.26

2 files

This release

0.0.25 This release

2 files

0.0.19

2 files

0.0.18

2 files

0.0.17

2 files

0.0.14

2 files

0.0.13

2 files

0.0.12

2 files

0.0.11

2 files

0.0.10

2 files

0.0.9

2 files

0.0.8

2 files

0.0.7

2 files

0.0.6

2 files

0.0.5

2 files

0.0.4

2 files

0.0.3

2 files

0.0.2

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page