mirror of
https://github.com/SuperClaude-Org/SuperClaude_Framework.git
synced 2025-12-17 09:46:06 +00:00
## Version Management & Consistency - Update to version 4.0.0b1 (proper beta versioning for PyPI) - Add __version__ attribute to SuperClaude/__init__.py - Ensure version consistency across pyproject.toml, __main__.py, setup/__init__.py ## Enhanced Package Configuration - Improve pyproject.toml with comprehensive PyPI classifiers - Add proper license specification and enhanced metadata - Configure package discovery with inclusion/exclusion patterns - Add development and test dependencies ## Publishing Scripts & Tools - scripts/build_and_upload.py: Advanced Python script for building and uploading - scripts/publish.sh: User-friendly shell wrapper for common operations - scripts/validate_pypi_ready.py: Comprehensive validation and readiness checker - All scripts executable with proper error handling and validation ## GitHub Actions Automation - .github/workflows/publish-pypi.yml: Complete CI/CD pipeline - Automatic publishing on GitHub releases - Manual workflow dispatch for TestPyPI uploads - Package validation and installation testing ## Documentation & Security - PUBLISHING.md: Comprehensive PyPI publishing guide - scripts/README.md: Detailed script usage documentation - .env.example: Environment variable template - Secure token handling with both .pypirc and environment variables ## Features ✅ Version consistency validation across all files ✅ Comprehensive PyPI metadata and classifiers ✅ Multi-environment publishing (TestPyPI + PyPI) ✅ Automated GitHub Actions workflow ✅ Security best practices for API token handling ✅ Complete documentation and troubleshooting guides ✅ Enterprise-grade validation and error handling The SuperClaude Framework is now fully prepared for PyPI publication with professional-grade automation, validation, and documentation. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
95 lines
2.9 KiB
Bash
Executable File
95 lines
2.9 KiB
Bash
Executable File
#!/bin/bash
|
|
"""
|
|
SuperClaude PyPI Publishing Helper Script
|
|
Easy-to-use wrapper for the Python build and upload script
|
|
"""
|
|
|
|
set -e # Exit on any error
|
|
|
|
# Colors for output
|
|
RED='\033[0;31m'
|
|
GREEN='\033[0;32m'
|
|
YELLOW='\033[1;33m'
|
|
BLUE='\033[0;34m'
|
|
NC='\033[0m' # No Color
|
|
|
|
# Get script directory
|
|
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
|
|
PROJECT_ROOT="$(dirname "$SCRIPT_DIR")"
|
|
BUILD_SCRIPT="$SCRIPT_DIR/build_and_upload.py"
|
|
|
|
echo -e "${BLUE}🚀 SuperClaude PyPI Publishing Helper${NC}"
|
|
echo -e "📁 Project root: $PROJECT_ROOT"
|
|
|
|
# Function to show usage
|
|
show_usage() {
|
|
echo -e "${YELLOW}Usage:${NC}"
|
|
echo " $0 test - Build and upload to TestPyPI"
|
|
echo " $0 test-install - Test installation from TestPyPI"
|
|
echo " $0 prod - Build and upload to production PyPI"
|
|
echo " $0 build - Only build the package"
|
|
echo " $0 clean - Clean build artifacts"
|
|
echo " $0 check - Validate project structure only"
|
|
echo ""
|
|
echo -e "${YELLOW}Examples:${NC}"
|
|
echo " $0 test # Upload to TestPyPI"
|
|
echo " $0 test && $0 test-install # Upload and test"
|
|
echo " $0 prod # Upload to production"
|
|
}
|
|
|
|
# Check if Python script exists
|
|
if [ ! -f "$BUILD_SCRIPT" ]; then
|
|
echo -e "${RED}❌ Build script not found: $BUILD_SCRIPT${NC}"
|
|
exit 1
|
|
fi
|
|
|
|
# Parse command
|
|
case "${1:-}" in
|
|
"test")
|
|
echo -e "${YELLOW}📦 Building and uploading to TestPyPI...${NC}"
|
|
python3 "$BUILD_SCRIPT" --testpypi
|
|
echo -e "${GREEN}✅ Uploaded to TestPyPI! Test with:${NC}"
|
|
echo -e " pip install --index-url https://test.pypi.org/simple/ SuperClaude"
|
|
;;
|
|
|
|
"test-install")
|
|
echo -e "${YELLOW}🧪 Testing installation from TestPyPI...${NC}"
|
|
python3 "$BUILD_SCRIPT" --testpypi --test-install --skip-build
|
|
;;
|
|
|
|
"prod"|"production")
|
|
echo -e "${YELLOW}🚨 Building and uploading to PRODUCTION PyPI...${NC}"
|
|
echo -e "${RED}⚠️ This cannot be undone!${NC}"
|
|
python3 "$BUILD_SCRIPT"
|
|
echo -e "${GREEN}✅ Uploaded to PyPI! Install with:${NC}"
|
|
echo -e " pip install SuperClaude"
|
|
;;
|
|
|
|
"build")
|
|
echo -e "${YELLOW}🔨 Building package only...${NC}"
|
|
python3 "$BUILD_SCRIPT" --skip-validation --testpypi --skip-upload
|
|
echo -e "${GREEN}✅ Package built in dist/ directory${NC}"
|
|
;;
|
|
|
|
"clean")
|
|
echo -e "${YELLOW}🧹 Cleaning build artifacts...${NC}"
|
|
python3 "$BUILD_SCRIPT" --clean
|
|
echo -e "${GREEN}✅ Build artifacts cleaned${NC}"
|
|
;;
|
|
|
|
"check"|"validate")
|
|
echo -e "${YELLOW}🔍 Validating project structure...${NC}"
|
|
python3 "$BUILD_SCRIPT" --skip-build --testpypi
|
|
;;
|
|
|
|
"help"|"-h"|"--help"|"")
|
|
show_usage
|
|
;;
|
|
|
|
*)
|
|
echo -e "${RED}❌ Unknown command: $1${NC}"
|
|
echo ""
|
|
show_usage
|
|
exit 1
|
|
;;
|
|
esac |