You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Daniele Tricoli 8015fa5964 Add Installation and Usage sections 5 years ago
nerone Initial import 5 years ago
.gitignore Initial import 5 years ago
LICENSE Initial import 5 years ago
README.rst Add Installation and Usage sections 5 years ago
setup.py Initial import 5 years ago

README.rst

nerone

nerone creates PyInstaller one-file executables with only dependencies for the scripts in arguments.

The name is a pun related to how one-file executables work: when they are started a temporary folder in the appropriate temp-folder location for the OS is created and PyInstaller bootloader uncompresses the support files and writes copies into the temporary folder.

The temporary folder is deleted after the code execution: this inspired the name of the project.

See PyInstaller documentation for details.

Installation

% pip install git+https://github.com/eriol/nerone

Usage

Suppose to have the following script named `test.py`:

import sys

import requests


if __name__ == '__main__':
    print requests.head(sys.argv[2]).headers

To create a one-file executable with all the dependencies (in this case only requests) you can just call nerone passing the script:

% nerone test.py

Inside dist directory you will find the one-file executable witch embed the dependencies for test.py.

% ./dist/test test.py https://mornie.org
{'Content-Encoding': 'gzip', 'Server': 'nginx/1.6.2', ...}