A Zsh alias manager for Kali Linux CTF setups, providing organization, syntax highlighting, and CLI management for aliases.
Features
- Categorizes aliases based on
# CTF Aliases
and# Other Aliases
sections - Truncated or full command preview with smart length management
- Syntax-highlighted output using
batcat
(if installed) - Add, edit, remove, or search aliases directly from terminal
- Instant
.zshrc
reload functionality - Built specifically for Kali Linux CTF environments
Quick Start
# Install dependencies (optional)
sudo apt install bat
# Download and setup
curl -L https://raw.githubusercontent.com/Tecttano/kali-utils/main/aliasman/aliasman -o aliasman
chmod +x aliasman
# Add to path (optional)
echo "alias aliasman='$PWD/aliasman'" >> ~/.zshrc
source ~/.zshrc
# Basic usage
aliasman # Default view (truncated)
aliasman --full # Show full commands
aliasman --add myalias # Add new alias
Installation
Quick Install
- Download the script:
curl -L https://raw.githubusercontent.com/Tecttano/kali-utils/main/aliasman/aliasman -o aliasman
chmod +x aliasman
- Make it globally accessible:
# Option 1: Add alias to .zshrc
echo "alias aliasman='$PWD/aliasman'" >> ~/.zshrc
source ~/.zshrc
# Option 2: Move to system path
sudo mv aliasman /usr/local/bin/
Usage Examples
Basic Commands
aliasman # Default view (truncated)
aliasman --full # Show full commands with syntax highlighting
aliasman --length 50 # Custom truncation length
Alias Management
aliasman --add myalias # Add a new alias
aliasman --edit myalias # Edit existing alias
aliasman --rm myalias # Remove an alias
aliasman --search word # Search through aliases
aliasman --reload # Reload .zshrc configuration
Sample Output
Alias Overview:
# CTF Aliases
scripts → cd ~/CTF/scripts
update → sudo apt update && sudo apt full-upgrade -y && sudo apt autoremove -y
nmap_quick → nmap -sS -O -F --version-intensity 0
# Other Aliases
ll → ls -l
la → ls -A
l → ls -CF
Command Options
Option | Description |
---|---|
--full |
Show full commands (uses batcat if available) |
--length N |
Truncate commands to N characters |
--add NAME |
Add a new alias interactively |
--edit NAME |
Edit an existing alias |
--rm NAME |
Remove an alias |
--search WORD |
Search aliases containing WORD |
--reload |
Reload .zshrc configuration |
Requirements
- Zsh shell with
.zshrc
file .zshrc
must contain# CTF Aliases
comment line for categorization- Optional:
bat
package for enhanced syntax highlighting - Designed specifically for Kali Linux environments
Notes
- Aliases under
# CTF Aliases
in.zshrc
are grouped separately from other aliases - The tool expects a specific comment structure in your
.zshrc
file - Best experience requires
batcat
installed for proper syntax highlighting - Primarily designed for CTF and penetration testing workflows
Troubleshooting
Common Issues
# If aliases don't appear, check .zshrc structure
grep "# CTF Aliases" ~/.zshrc
# Verify batcat installation for syntax highlighting
which batcat || sudo apt install bat
# Check permissions
ls -la aliasman
chmod +x aliasman # If needed