Skip to main content
KX-Publish-PyPI Logo

KX-Publish-PyPI

The Professional CLI Tool for Python Package Publishing

PyPI version Python 3.9+ License: MIT Build Status GitHub stars

Publish Python packages to PyPI in under 30 seconds!

Author: ABUELTAYEF Khader | Python 3.9+


🎯 Why Choose KX-Publish-PyPI?

Feature KX-Publish-PyPI Traditional Methods
Setup Time ⚡ 30 seconds ⏰ 30+ minutes
Security 🔐 System keyring 📝 Plain text files
User Experience 🎨 Rich CLI + Progress bars 📟 Basic terminal output
Error Handling 🛡️ Smart validation ❌ Manual debugging
Version Management 📈 Intelligent bumping 🔢 Manual editing
Build Backend Support 🛠️ All modern backends ⚙️ Limited support

💻 Installation

⚡ Quick Install

pip install kx-publish-pypi

✅ Verify Installation

kx-publish-pypi --version

💻 Account Setup & Token Generation

🔑 Get Started with PyPI Publishing

1. Create PyPI Account

  1. 🌐 Visit pypi.org
  2. 📝 Click "Register" in the top right
  3. ✉️ Fill out the registration form
  4. ✅ Verify your email address

2. Create TestPyPI Account

  1. 🌐 Visit test.pypi.org
  2. 📝 Click "Register" in the top right
  3. ✉️ Fill out the registration form
  4. ✅ Verify your email address

3. Generate API Tokens

For PyPI Production:

  1. 🔑 Log in to pypi.org
  2. ⚙️ Go to Account SettingsAPI tokens
  3. ➕ Click "Add API token"
  4. 🏷️ Give it a name (e.g., "kx-publish-pypi")
  5. 💾 Copy & Save the token (you won't see it again!)

For TestPyPI:

  1. 🔑 Log in to test.pypi.org
  2. ⚙️ Go to Account SettingsAPI tokens
  3. ➕ Click "Add API token"
  4. 🏷️ Give it a name (e.g., "kx-publish-pypi-test")
  5. 💾 Copy & Save the token

4. Store Tokens Securely

Use the CLI to store your tokens securely:

kx-publish-pypi setup-tokens

This will prompt you to enter your TestPyPI and PyPI tokens, which will be stored in your system's keyring.

💡 Pro Tip: You can also store tokens directly during the guided workflow:

kx-publish-pypi run

🚀 Quick Start

Choose Your Publishing Journey

🎯 Option 1: Complete Guided Workflow (Recommended)

kx-publish-pypi run
One command handles everything: checks, tokens, version bump, build, and publish

🛠️ Option 2: Individual Commands

# 🔍 Pre-flight check your package
kx-publish-pypi check

# 🔐 Setup API tokens securely
kx-publish-pypi setup-tokens

# 📈 Bump version (patch/minor/major)
kx-publish-pypi bump patch

# 🧪 Publish to TestPyPI first
kx-publish-pypi publish-test

# 🚀 Publish to production PyPI
kx-publish-pypi publish-prod

Key Features

🎨 Rich Interface Rich, colorful output with progress bars
🔍 Smart Pre-checks Validates package structure and configuration
🔐 Secure Token Storage Uses system keyring for API tokens
📦 Enhanced Version Detection Supports all modern Python build backends
🔥 Interactive Workflow Guided experience from check to publish
📈 Version Management Intelligent version bumping
🛠️ Build Integration Works with setuptools, flit, hatchling, etc.

🏗️ Supported Build Backends

Backend Status Version Detection
setuptools ✅ Full Support __version__ files
poetry ✅ Full Support pyproject.toml
flit ✅ Full Support pyproject.toml
hatchling ✅ Full Support pyproject.toml
pdm ✅ Full Support pyproject.toml
scikit-build ✅ Full Support Custom detection

🚀 Programmatic API

from kx_publish_pypi import detect_package_version
from pathlib import Path

# Enhanced version detection
result = detect_package_version(Path("."))
if result.version_info:
    print(f"📦 Version: {result.version_info.version}")
    print(f"🔧 Method: {result.version_info.method}")

🤝 Contributing

We welcome contributions! Please see our Contributing Guide for details.

🐛 Found a Bug?


📄 License

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


🌐 Connect with Us

🚀 Powered by KhaderX | 👨‍💻 Founder: ABUELTAYEF Khader

GitHub Website PyPI

⭐ If you find this tool useful, please star this repo!

GitHub stars
KX-Publish-PyPI Logo

Download files

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

Source Distribution

kx_publish_pypi-1.0.3.tar.gz (26.9 kB view details)

Uploaded Source

Built Distribution

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

kx_publish_pypi-1.0.3-py3-none-any.whl (26.5 kB view details)

Uploaded Python 3

File details

Details for the file kx_publish_pypi-1.0.3.tar.gz.

File metadata

  • Download URL: kx_publish_pypi-1.0.3.tar.gz
  • Upload date:
  • Size: 26.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.7

File hashes

Hashes for kx_publish_pypi-1.0.3.tar.gz
Algorithm Hash digest
SHA256 ae018aa829e3b9e273a2a22f0866e9a2f43c716c75d75e6501bad7e9aaa2b46a
MD5 25f14ea35d90d5c97efd68fc21ed9057
BLAKE2b-256 afbe32a6118eec7dad312ead02185de6135f72ab53d4ad5b7f44f9770a6c6c26

See more details on using hashes here.

File details

Details for the file kx_publish_pypi-1.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for kx_publish_pypi-1.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 ec8b231925de7f5d6c8409998b7fe433cda693e7d0e4adc424fce43b9d5a039b
MD5 84e789db4e92751aa4a34cf6e4908560
BLAKE2b-256 4f4daa6a19ad249b41b2edd99594081e6efb19ad8ecbc0b8259a33c887dccc51

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.3 This release

2 files

1.0.2

2 files

1.0.1

2 files

1.0.0

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