Skip to main content

A template for a private Python package

Project description

Private Python Package Template

For private packages hosting we use CloudSmith because of their generous free tier.

Using This Template for Your Own Package (e.g., "my_package")

To adapt this template for your new package (let's call it "my_package"):

  1. Copy or Template the Repository:

    • Click the "Use this template" button on GitHub to create a new repository from this template.
  2. Rename the Package Directory:

    • Rename the main package directory in src dir
  3. Update pyproject.toml:

    • [project].name: Change from "private_package_template" to "my_package".
    • [project].urls: Update Homepage and Repository URLs to point to your new repository.
  4. Set up bump version:

    1. Go to: https://github.com/settings/personal-access-tokens/new?type=beta
    2. Set permission "Contents" to Read & Write
    3. Create a repository secret with the name BUMPVERSION_TOKEN
    4. It is recommended to make the main branch protected as every push/merge/commit to it will trigger a bump version.
  5. Set up PyPI

    1. Go to: https://pypi.org/manage/account/token/
    2. Click "Add API token", set the scope for your package
    3. Create a repository secret with the name PYPI_PUBLISH_TOKEN
  6. Once you push anything to main, a new tag will be created, built, and published to PyPI

Installing Your Published Private Package

Then you can just pip install your package.

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

yid_public_package_template-0.1.13.tar.gz (2.8 kB view details)

Uploaded Source

Built Distribution

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

yid_public_package_template-0.1.13-py3-none-any.whl (3.0 kB view details)

Uploaded Python 3

File details

Details for the file yid_public_package_template-0.1.13.tar.gz.

File metadata

File hashes

Hashes for yid_public_package_template-0.1.13.tar.gz
Algorithm Hash digest
SHA256 9aff3fbaec82f7ead808b7f945344664f26e88871ea3328b9a4c7d52f2b31b7b
MD5 dff2e9f7fc595cdc931d95d10e5fc9be
BLAKE2b-256 00950e11025bce12a823ac25282319d3bd87ff5f683708488aeb36a93aba6d8c

See more details on using hashes here.

File details

Details for the file yid_public_package_template-0.1.13-py3-none-any.whl.

File metadata

File hashes

Hashes for yid_public_package_template-0.1.13-py3-none-any.whl
Algorithm Hash digest
SHA256 bee8a89a1556acd94e46fb0fc32afcab4fc1af7ac925dd16c8554c8bf3c73332
MD5 f561beddce082ddec27569b4d2ea168b
BLAKE2b-256 2a395d62936d10d2b9b4ff81ea7c41c226a4c975784c0c686b3690ce835ba8fc

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