Skip to main content

PyStand-cli

This tool packages a Python project into a standalone executable using PyStand and embeddable Python. It supports excluding specific directories and files, and provides a progress bar for file copying.


Installation

  1. Install:

    pip install pystand-cli
    
  2. Upgrade:

    pip install --upgrade pystand-cli
    

Usage

Basic Command

pystand-cli entry_script.py [OPTIONS]

Options

Option Description
--project-dir The project directory (optional).
--exclude-dirs Folders to exclude (optional, can be specified multiple times).
--exclude-files Files to exclude (optional, can be specified multiple times).
--output-dir The output directory (optional, default is dist).
--noconsole Run the application without a console window (optional).
--python-repo The Python FTP repository URL (optional, default is https://www.python.org/ftp/python).

Examples

  1. Package a project with an entry script:

    pystand-cli entry_script.py --project-dir /path/to/project
    
  2. Exclude specific directories and files:

    pystand-cli entry_script.py --project-dir /path/to/project --exclude-dirs node_modules --exclude-files .gitignore
    
  3. Run without a console window:

    pystand-cli entry_script.py --project-dir /path/to/project --noconsole
    
  4. Custom output directory:

    pystand-cli entry_script.py --project-dir /path/to/project --output-dir /path/to/output
    

Output Structure

The output directory will contain the following structure:

output_dir/
├── runtime/                # Embeddable Python runtime
├── site-packages/          # Python site packages
├── main.exe                # PyStand executable
├── main.py                 # Entry script
└── ...                     # Other files and directories

Notes

  • Embeddable Python: The tool downloads the embeddable Python runtime from the official Python FTP repository.
  • PyStand: PyStand is used to create a standalone executable from the entry script.
  • Exclusion: Excluded directories and files are not copied to the output directory.
  • GUI Applications: Use the --noconsole option to run the application without a console window. CLI applications should not use this option.

License

This project is licensed under the MIT License. See the LICENSE file for details.


Contributing

Please open an issue or submit a pull request.


Acknowledgments

  • PyStand by skywind3000.
  • Click for command-line interface support.

Metadata

Release files for pystand-cli 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pystand-cli 0.1.0
File Size Uploaded
pystand_cli-0.1.0.tar.gz 4.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pystand-cli 0.1.0
File Interpreter ABI Platform
pystand_cli-0.1.0-py3-none-any.whl Python 3 none any Details

Total release size: 10.3 kB

Release files / pystand_cli-0.1.0.tar.gz

Download URL pystand_cli-0.1.0.tar.gz
Size 4.6 kB
Tags Source
SHA-256 checksum
How to use checksums
cc0f52678233075c16e88416957d8826b887e28e167190a4b7ef3a1d3f418e2b
BLAKE2b-256 checksum
How to use checksums
65e95152961458de0754539663c752a5dd42c39f4a1f6659fbfd27f1502cc0b1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release files / pystand_cli-0.1.0-py3-none-any.whl

Download URL pystand_cli-0.1.0-py3-none-any.whl
Size 5.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
71ace064fa9d9e425cbfb6cd0aa10c6994467fb33f3fd47b3fc68227da179ffb
BLAKE2b-256 checksum
How to use checksums
ec1b0117cabc0c2e56353ad00203de315bb7a7373c427b695ce9c6356afdbf6c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.12.9

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Apr 2, 2025.

Transparency log

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release 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