Cross-platform Command Manager - Simplify your terminal with intuitive shortcuts
Project description
๐ง CCMD โ Custom Command Manager
Cross-platform command enhancer for humans. Replace long, repetitive terminal syntax with short, intuitive commands. Works on Linux, Windows PowerShell, and WSL โ safe, rollback-ready, and open source.
๐ง New in v1.1.6: Bug Fix Release! Fixed critical argument passing bug and command chaining password bypass. Commands like
sudo apt updatenow work correctly.
๐ v1.1.5: Advanced Security Release! Internal flag protection, atomic shell writes, path diagnostics, threat model documentation, and automated dependency scanning. See Security Report
๐ก๏ธ v1.1.4: Security Hardening Release! 0 HIGH vulnerabilities, comprehensive security audit, automated scanning, and professional security documentation.
โ ๏ธ Important: CCMD is a powerful tool that sits between your shell and you. Like electricity or any powerful tool, it can be dangerous if used wrongly. Please read the Security Policy and Threat Model before using CCMD. Use carefully, cautiously, and responsibly.
๐ Version Notice: We strongly recommend using v1.1.5 or later. This version includes critical security enhancements and passes all automated security scans with comprehensive threat model documentation. Upgrade now โ it's safe, fast, and backward compatible!
๐งฉ Overview
CCMD is an open-source project developed by De Catalyst (Wisyle).
It lets you define simple, natural shortcuts for everyday shell operations โ no more typing endless flags or remembering weird syntax.
Instead of typing:
cd ~/Downloads
git add .
git commit -m "update"
git push
You can just write:
go downloads
push
CCMD handles the rest. It safely installs into your shell profile, manages custom commands through YAML, and supports plugins, system monitoring, and SSH management.
โจ Features
๐ v1.1.5 Advanced Security (LATEST!)
- ๐ Internal Flag Protection โ
--exechidden from help, environment-gated for internal use only - โ๏ธ Atomic Shell Config Writes โ Prevents corruption with temp file + atomic rename pattern
- ๐ฉบ Path Diagnostics Command โ
--check-pathsvalidates installation, environment, and backups - ๐ก๏ธ Threat Model Documentation โ Complete attack scenarios, mitigations, and security boundaries (THREAT_MODEL.md)
- ๐ Recovery Guide โ Emergency procedures for all failure scenarios (RECOVERY.md)
- ๐ฆ Dependabot Integration โ Weekly automated dependency vulnerability scanning
- ๐ Enhanced CI Scanning โ Safety dependency scanner added to security workflow
- ๐ Security Metrics โ 0 HIGH severity issues maintained, all 7 audit items addressed
Security Achievement: Comprehensive threat model, automated scanning, and emergency recovery procedures!
๐ก๏ธ v1.1.4 Security Hardening
- ๐ก๏ธ Tarfile Path Traversal Fixed โ Prevents malicious archives from writing outside target directory (CVE-2007-4559)
- ๐ URL Scheme Validation โ Restricts all URL operations to HTTPS only, prevents downgrade attacks
- ๐ฆ Dependency Security โ GitPython pinned to v3.1.43, eliminates 6 known vulnerabilities
- ๐ค Automated Security Scanning โ Bandit and Safety integrated with GitHub Actions
- ๐ Security Policy โ Professional vulnerability reporting process (48-hour response time)
- ๐ Security Metrics โ 0 HIGH severity issues, all dependencies secured
- ๐ Security Changelog โ Complete audit trail of all security improvements
- โ๏ธ CodeQL Analysis โ Semantic code analysis detects vulnerabilities automatically
๐ v1.1.3 Bug Fixes
- ๐ง Fixed Directory Persistence โ Chained commands now correctly persist directory changes
- โฑ๏ธ Fixed Interactive Timeouts โ Interactive commands like
claudeno longer timeout - ๐ฆ Fixed Pip Install Warnings โ Automatic handling of externally-managed Python environments
- โ Enhanced Navigation โ Support for custom project directory paths in
gocommand - ๐ฏ 180s Timeout for Non-Interactive โ Non-interactive commands timeout after 3 minutes (prevents hangs)
๐ v1.1.2 Features
- ๐ Command Chaining โ Chain commands with
>>>operator:go downloads >>> ls >>> echo "done" - ๐ Command Composability โ CCMD commands can call other CCMD commands
- ๐ฏ Smart Directory Chaining โ Directory changes persist through command chains
- ๐ก๏ธ Enhanced Security โ Context-aware validation, expanded pattern detection (40+ patterns)
- ๐ Process Management โ
kapkills all processes (with confirmation),kpkills by name - ๐ bcrypt Fallback โ PBKDF2-HMAC-SHA256 fallback if bcrypt unavailable
- ๐ Type Enforcement โ Custom commands cannot abuse privileged types
Example: ccmd add โ name: devwork โ command: go projects >>> ls >>> echo "Ready to code!"
๐ v1.1.1 Security Features
- ๐ Master Password System โ Protect sensitive commands with bcrypt-hashed passwords
- ๐ก๏ธ Command Injection Prevention โ Automatic blocking of dangerous command patterns
- ๐ SSH Key Validation โ Verify key permissions (0600) before use
- ๐ Sensitive Command Detection โ Auto-detect and protect sudo, ssh, AWS commands
- ๐ Atomic File Operations โ Safe, corruption-proof file writes
- ๐ฏ Intelligent Auto-Locator โ No more path issues, works anywhere
- ๐ Audit Logging โ Track all authentication attempts
- โก Security Cache โ 5-minute authentication window for convenience
New Commands: init, debug, sudo, change-password, reset-password, kap, kp
๐ v1.1.0 Features
- โจ Custom Commands โ Create your own commands with
add, manage withremove - ๐ Instant Reload โ
reloadcommand updates config without manual reinstall - ๐ฏ Interactive Push โ Full git workflow with file selection and auto-commit messages
- ๐ Command Manager โ Enable/disable commands with
list - ๐ก๏ธ Graceful Cancellation โ Press Ctrl+C anytime without ugly errors
- ๐ Better Windows Support โ Fully tested on PowerShell with proper encoding
Core Features
- Cross-Platform Support โ Linux, WSL, Windows PowerShell (macOS code exists but untested*)
- Natural Commands โ No prefixes; just type
go,push,cpu, etc. - Smart Directory Navigation โ Search and jump to directories anywhere
- Auto Git Integration โ Interactive add, commit, and push workflow
- System Insights โ Monitor CPU, memory, and processes
- Safe Rollback โ Backs up your shell configuration before any changes
- Persistent Customization โ Your custom commands survive CCMD updates
- Password Protection โ Mark custom commands as requiring authentication
*macOS users: We need your feedback! Please test and report issues.
๐ Documentation
For detailed guides and technical documentation, see:
- ๐ Security Policy โ READ THIS FIRST! Vulnerability reporting and security measures
- ๐ Security Changelog โ Complete audit trail of security improvements
- ๐ค Claude AI Security Audit โ Professional AI security scan (Score: 7.8/10 - GOOD)
- ๐ก๏ธ Threat Model โ Complete attack scenarios and mitigations
- ๐ Recovery Guide โ Emergency recovery procedures for all platforms
- ๐ Release Notes v1.1.4 โ Latest security hardening release
- ๐ Release Notes v1.1.3 โ Bug fixes and improvements
- Features โ Complete feature list including security features
- Installation Guide โ Step-by-step installation for all platforms
- Usage Guide โ Complete command reference and usage examples
- Configuration Guide โ Customize and create your own commands
- Troubleshooting โ Common issues and solutions
- Architecture โ Technical architecture and development guide
๐งฑ Project Structure
ccmd/
โโโ cli/
โ โโโ main.py # CLI entrypoint
โ โโโ install.py # Installation and PATH setup
โ โโโ editor.py # Interactive command editor
โ โโโ ssh_manager.py # Manage SSH aliases and keys
โโโ core/
โ โโโ parser.py # Parse and map custom commands
โ โโโ executor.py # Execute commands securely
โ โโโ registry.py # Manage alias storage
โ โโโ rollback.py # Backup & restore shell configs
โ โโโ system_check.py # Detect OS and compatibility
โโโ commands.yaml # Default command definitions
โโโ run.py # Master entrypoint
โโโ setup.sh # Unix installer
โโโ setup.ps1 # Windows installer
โโโ LICENSE
โโโ README.md
๐ Installation
Prerequisites
- Python 3.7+
- pip (usually included with Python)
Method 1: Install from PyPI (Recommended) โญ
The easiest way to install CCMD:
pip install ccmd
That's it! CCMD is now available as the ccmd command globally.
Test installation:
ccmd --version
ccmd --list
Note: PyPI installation provides the CCMD package but you may still need to run shell integration for full functionality:
ccmd --install # Sets up shell integration (one-time setup)
Method 2: Install from GitHub (For Development)
For users who want the latest development version or want to contribute:
# Clone the repository (ccmd branch)
git clone -b ccmd https://github.com/Wisyle/ccmd.git
cd ccmd
# Run the installer for your platform
# Linux/macOS/WSL:
bash setup.sh
# Windows PowerShell:
.\setup.ps1
# Reload your shell
source ~/.bashrc # or ~/.zshrc for Zsh, or restart terminal
Method 3: Download Release ZIP (Offline Install)
If you don't have pip or git access:
-
Download the latest release:
- Visit: https://github.com/Wisyle/ccmd/releases/latest
- Download Source code (zip) under Assets
- Or direct download: https://github.com/Wisyle/ccmd/archive/refs/tags/v1.1.4.zip
-
Extract and install:
# Linux/macOS/WSL: cd /path/to/ccmd bash setup.sh source ~/.bashrc # Windows PowerShell: cd C:\path\to\ccmd .\setup.ps1 . $PROFILE
Verify Installation
After installation, test that CCMD is working:
# Check system status
ccmd --check
# List available commands
ccmd --list
# Test a command
go home
Update CCMD
If installed via PyPI (recommended):
pip install --upgrade ccmd
If installed via Git:
cd /path/to/ccmd
git pull origin ccmd
python3 run.py --install
If installed via ZIP:
- Download the latest version from PyPI:
pip install --upgrade ccmd - Or download latest ZIP and reinstall
Uninstall
If installed via PyPI:
pip uninstall ccmd
ccmd --restore # Optional: restore shell config
If installed via Git/ZIP:
python3 run.py --restore # Removes shell integration
๐ง Default Commands
Navigation
| Command | Description | Example |
|---|---|---|
go <dir> |
Navigate to directory or search | go downloads |
Git Operations
| Command | Description | Notes |
|---|---|---|
push |
Interactive git add, commit, and push | Auto-generates commit messages ๐ |
System Monitoring
| Command | Description | Platform Support |
|---|---|---|
cpu |
Show CPU usage | Linux, macOS, Windows |
mem |
Show memory usage | Linux, macOS, Windows |
proc |
List running processes | Linux, macOS, Windows |
kap |
Kill process by PID | Linux, macOS, Windows |
Custom Commands ๐ v1.1.0
| Command | Description | Notes |
|---|---|---|
add |
Create a custom command | Interactive prompts |
remove |
Delete a custom command | Shows list to select from |
list |
Manage commands (enable/disable) | Toggle commands on/off |
CCMD Management
| Command | Description | Notes |
|---|---|---|
reload |
Reload config and update shell ๐ | No manual reinstall needed |
update |
Update CCMD from GitHub | Downloads latest version |
version |
Show current and latest version | Checks GitHub releases |
restore |
Restore shell config from backup | Rollback changes |
uninstall |
Remove CCMD completely | Cleans everything |
hi |
Show system dashboard | System overview |
โ๏ธ Configuration
Default Commands
CCMD default commands are defined in $CCMD_HOME/commands.yaml. These are managed by CCMD and updated when you upgrade.
Custom Commands (v1.1.0+)
Your custom commands are stored separately in:
~/.ccmd/custom_commands.yaml
Why separate? Your custom commands survive CCMD updates and never get overwritten.
Create custom commands:
add # Interactive command creation
Remove custom commands:
remove # Interactive command removal
Reload after manual edits:
reload # Reloads config and updates shell
Each command follows this format:
mycommand:
description: "What this command does"
action: "the shell command to execute"
type: custom
interactive: false # Set to true for commands needing user input
๐ Security & Safety
Security Score: 7.8/10 (GOOD) โ
CCMD has been professionally audited using both Bandit static analysis and Claude AI security scanning. See SECURITY_AUDIT_CLAUDE.md for the complete AI security audit report.
Scan Results:
- โ 0 HIGH severity issues (Bandit)
- โ 0 critical vulnerabilities (Claude AI)
- โ All dependencies secured (Safety + Dependabot)
- โ Comprehensive threat model documented
Security Comparison vs Similar Tools
CCMD beats oh-my-zsh and bash-it in ALL security categories:
| Security Feature | CCMD | oh-my-zsh | bash-it | Verdict |
|---|---|---|---|---|
| Command Injection Protection | โ Strong (40+ patterns) | โ ๏ธ Basic | โ ๏ธ Basic | CCMD Best |
| Password Protection | โ Yes (bcrypt) | โ No | โ No | CCMD Best |
| Atomic Shell Writes | โ Yes (v1.1.5) | โ No | โ No | CCMD Best |
| Backup/Restore | โ Built-in | โ ๏ธ Manual | โ ๏ธ Manual | CCMD Best |
| Security Documentation | โ Comprehensive | โ ๏ธ Limited | โ ๏ธ Limited | CCMD Best |
| Dependency Scanning | โ Automated (CI/CD) | โ No | โ No | CCMD Best |
| Cross-Platform Support | โ Win/Linux/Mac | โ Unix only | โ Unix only | CCMD Best |
| Threat Model | โ Documented | โ No | โ No | CCMD Best |
Security Features
- โ Backups created automatically before modifying any shell files
- โ
Rollback available anytime with
--restore - โ SSH keys are never stored or transmitted
- โ
Safe execution via subprocess calls, never
eval - โ Command validation with 40+ dangerous pattern detection
- โ Master password protection for sensitive commands
- โ Atomic writes prevent shell config corruption
- โ Automated scanning with Bandit, Safety, and CodeQL
๐งช Testing Locally
Before global install, run:
python run.py --test
This simulates:
- Shell detection and rc edits
- Git and system command execution
- Rollback and uninstall checks
๐งฐ Example Usage
# Navigate fast
go downloads
# Push Git changes instantly
push
# Check system load
cpu
# Connect to your default server
ssh
๐ Contributing
Contributions are welcome!
Fork the repo, create a branch, make your edits, and open a pull request.
A contribution guide will soon be added in /docs/CONTRIBUTING.md.
๐ License
Released under the MIT License. Free to use, modify, and distribute.
๐งโ๐ป Developed By
De Catalyst GitHub: @Wisyle Email: Robert5560newton@gmail.com X (Twitter): @iamdecatalyst Instagram: @iamdecatalyst Telegram: @iamdecatalyst
For bug reports, updates, or collaboration inquiries, feel free to reach out.
๐ช Tagline
โStop remembering commands. Start commanding naturally.โ
Always check new releases before downloading
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
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file ccmd-1.1.7.tar.gz.
File metadata
- Download URL: ccmd-1.1.7.tar.gz
- Upload date:
- Size: 67.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
9b00b67bf55ae0378365d85a52e5c0f89e5b5a1790fc5416b7806697af9e861c
|
|
| MD5 |
ca55b28762816d14ad97bef5accd9ba6
|
|
| BLAKE2b-256 |
f9db8100d12ea5d52d1912923d2e523070d454bd4b1818b7436656370a09d11e
|
File details
Details for the file ccmd-1.1.7-py3-none-any.whl.
File metadata
- Download URL: ccmd-1.1.7-py3-none-any.whl
- Upload date:
- Size: 63.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.12.3
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5eaf74078d7504f655aa3e2a8497b3a467454b3ee4e81457a784b1aad0172cb0
|
|
| MD5 |
6b7ddcb04cd0bece562b93221bf8022e
|
|
| BLAKE2b-256 |
c0303bc726470be05b80e77b2bbc710bfe1fe0a7b2f2ae712a943bcc5885c554
|