Installation Guide¶
This guide will walk you through the different ways to install Conventional Commits Generator (CCG).
Requirements¶
Before installing CCG, make sure you have:
- Python 3.9 or higher
- Git (required for git operations)
- pip or pipx (Python package installers)
Checking Your Python Version¶
If you don't have Python 3.9+, download it from python.org.
Installation Methods¶
Method 1: pipx (Recommended)¶
Why pipx?
pipx installs Python CLI applications in isolated environments, preventing dependency conflicts and making it easy to manage and update tools.
Install pipx¶
Install CCG with pipx¶
Verify Installation¶
Method 2: pip¶
Global Installation
Installing with pip globally may cause dependency conflicts with other Python packages. Consider using a virtual environment or pipx instead.
Using a Virtual Environment (Recommended)¶
# Create virtual environment
python3 -m venv ccg-env
# Activate virtual environment
source ccg-env/bin/activate
# Install CCG
pip install conventional-commits-generator
# Verify installation
ccg --version
Manual Setup (Alternative)¶
# Clone the repository
git clone https://github.com/EgydioBNeto/conventional-commits-generator.git
cd conventional-commits-generator
# Create virtual environment
python3 -m venv .venv
# Activate virtual environment
source .venv/bin/activate
# Install in development mode
pip install -e .
# Install with all dependencies (dev + test + docs)
pip install -e ".[dev,test,docs]"
Verifying Installation¶
After installation, verify that CCG is working correctly:
# Check version
ccg --version
# Display help
ccg --help
# Test in a git repository
cd /path/to/your/git/repo
ccg --commit
You should see the CCG ASCII logo and interactive prompts.
Updating CCG¶
pipx¶
pip¶
Uninstalling CCG¶
pipx¶
pip¶
Troubleshooting¶
Command not found: ccg¶
Problem: After installation, running ccg shows "command not found"
Solutions:
- Check if the installation directory is in your PATH:
# For pipx
pipx ensurepath
# For pip (user install)
export PATH="$HOME/.local/bin:$PATH" # Add to ~/.bashrc or ~/.zshrc
- Try running with python -m:
- Reinstall with correct method:
Permission Denied¶
Problem: Installation fails with permission errors
Solutions:
- Use user installation (recommended):
- Use pipx (recommended):
- Avoid sudo pip (not recommended):
Using sudo pip can break your system Python packages.
Dependency Conflicts¶
Problem: Conflicts with prompt_toolkit or other dependencies
Solutions:
- Use pipx (installs in isolated environment):
- Use virtual environment:
Python Version Mismatch¶
Problem: Your Python version is below 3.9
Solutions:
-
Install Python 3.9+ from python.org
-
Use version managers:
Import Errors¶
Problem: ModuleNotFoundError: No module named 'ccg'
Solutions:
-
Ensure installation completed:
-
Check if you're in the correct virtual environment:
- Reinstall:
Need Help?¶
- Check our FAQ
- Report issues on GitHub
- Read the Usage Guide for detailed command documentation