Now liveThe Skillselion MCP - thousands of ranked skills, loaded into your agent mid-task. No install.Get it →
athola avatar

Python Packaging

  • 102 installs
  • 325 repo stars
  • Updated August 2, 2026
  • athola/claude-night-market

Wire GitHub Actions with uv to test, lint, type-check, build, and publish Python packages to PyPI on release.

About

Python-packaging’s CI/CD Integration module teaches solo builders how to automate the boring part of shipping a Python library: every push and pull request runs tests and quality checks, and a published GitHub Release triggers a build and PyPI upload using uv and Astral’s setup action. The skill is aimed at indie maintainers who already have a uv-based project layout and want reproducible workflows without hand-rolling twine and legacy setuptools scripts. You reach for it when you are ready to stop manual releases or when you need a credible test matrix before you share a package on skills.sh-style agent ecosystems or internal tooling. The YAML snippets are intentionally minimal so you can drop them into `.github/workflows` and extend with caching, signing, or trusted publishing later. It pairs naturally with packaging metadata and versioning work in the parent python-packaging skill rather than replacing project scaffolding.

  • Copy-paste publish workflow on `release: published` with `uv build` and `uv publish`
  • Matrix test job across Python 3.9–3.12 using `astral-sh/setup-uv`
  • Combined CI pipeline: pytest with coverage, Ruff, and mypy on push/PR
  • Child module of python-packaging focused on GitHub Actions only
  • Secrets pattern via `UV_PUBLISH_TOKEN` / `PYPI_TOKEN`

Python Packaging by the numbers

  • 102 all-time installs (skills.sh)
  • Ranked #546 of 1,435 DevOps & CI/CD skills by installs in the Skillselion catalog
  • Security screen: LOW risk (skills.sh audit)
  • Data as of Aug 5, 2026 (Skillselion catalog sync)
npx skills add https://github.com/athola/claude-night-market --skill python-packaging

Add your badge

Show developers this skill is listed on Skillselion. Paste this into your README.

Listed on Skillselion
Installs102
repo stars325
Security audit3 / 3 scanners passed
Last updatedAugust 2, 2026
Repositoryathola/claude-night-market

What it does

Wire GitHub Actions with uv to test, lint, type-check, build, and publish Python packages to PyPI on release.

Files

SKILL.mdMarkdownGitHub ↗

Table of Contents

Python Packaging

Modern Python packaging with pyproject.toml, uv, and best practices for distribution.

Quick Start

# Create new project with uv
uv init my-package
cd my-package

# Add dependencies
uv add requests click

# Build package
uv build

# Publish to PyPI
uv publish

Verification: Run the command with --help flag to verify availability.

When To Use

  • Creating distributable Python libraries
  • Building CLI tools
  • Publishing to PyPI
  • Setting up development environments
  • Managing project dependencies

When NOT To Use

  • Testing packages - use python-testing

instead

  • Optimizing package performance - use python-performance
  • Testing packages - use python-testing

instead

  • Optimizing package performance - use python-performance

Core Decisions

1. Layout Choice

# Source layout (recommended)
src/my_package/
    __init__.py
    module.py

# Flat layout (simple)
my_package/
    __init__.py
    module.py

Verification: Run the command with --help flag to verify availability.

Source layout benefits:

  • Clear separation of source and tests
  • Prevents accidental imports of uninstalled code
  • Better for packages with complex structure

2. Project Structure

Minimal Project:

**Verification:** Run `pytest -v` to verify tests pass.
my-project/
├── pyproject.toml
├── README.md
├── src/
│   └── my_package/
│       └── __init__.py
└── tests/
    └── test_init.py

Verification: Run pytest -v to verify tests pass.

Complete Project:

**Verification:** Run the command with `--help` flag to verify availability.
my-project/
├── pyproject.toml
├── README.md
├── LICENSE
├── .gitignore
├── src/
│   └── my_package/
│       ├── __init__.py
│       ├── cli.py
│       ├── core.py
│       └── utils.py
├── tests/
│   ├── conftest.py
│   └── test_core.py
└── docs/
    └── index.md

Verification: Run pytest -v to verify tests pass.

Detailed Topics

See modules for detailed information:

  • [uv Workflow](modules/uv-workflow.md) - Complete uv commands and troubleshooting
  • [pyproject.toml Patterns](modules/pyproject-patterns.md) - Configuration examples for different package types
  • [Entry Points](modules/entry-points.md) - Console scripts, GUI scripts, and plugins
  • [CI/CD Integration](modules/ci-cd-integration.md) - GitHub Actions and automated publishing

Best Practices

1. Use source layout for anything beyond simple packages 2. Pin direct dependencies with minimum versions 3. Use optional dependency groups for dev/docs/test 4. Include py.typed for type hint support 5. Add detailed README with usage examples 6. Use semantic versioning (MAJOR.MINOR.PATCH) 7. Test on multiple Python versions before publishing

Exit Criteria

  • Modern pyproject.toml configuration
  • Clear dependency specification
  • Proper version management
  • Tests included and passing
  • Build process reproducible
  • Publishing pipeline automated

Related skills

FAQ

Is Python Packaging safe to install?

skills.sh reports 3 of 3 security scanners passed. Review the Security Audits panel on this page before installing in production.

DevOps & CI/CDdevopsbackend

This week in AI coding

Five minutes, every Monday - the tools, releases and tactics for developers.

unsubscribe anytime.