The Doskey Alias Manager is a Python script designed to simplify the management of command aliases in the Windows Command Prompt (CMD). This tool allows users to create, update, and remove doskey aliases easily, as well as automatically configure their system to run a batch file on CMD startup.
- Add new aliases: Create new doskey commands with ease.
- List existing commands: View all current doskey aliases and their corresponding commands.
- Remove commands: Delete specific doskey aliases by their index.
- Automatic setup: Automatically sets up a batch file to run doskey commands when CMD is opened.
- Registry integration: Updates the Windows Registry to ensure that specified batch files run on startup.
- Python 3.x
- Windows operating system
-
Clone this repository:
git clone https://github.com/yourusername/doskey-alias-manager.git cd doskey-alias-manager -
Ensure you have Python installed on your system. You can download it from python.org.
-
Run the script:
python doskey_alias_manager.py --install
You can manage your doskey aliases using command-line arguments:
-
Set a new alias:
python doskey_alias_manager.py --set "alias=command"Example:
python doskey_alias_manager.py --set "myip=curl https://api.ipify.org" -
Show version:
python doskey_alias_manager.py --version
-
Print all aliases:
python doskey_alias_manager.py --print
-
Remove an alias by index:
python doskey_alias_manager.py --remove <index>
Example:
python doskey_alias_manager.py --remove 1
-
Install the pcmd alias (copies the script to the doskey folder):
python doskey_alias_manager.py --install
When you print all commands, you will see output similar to this:
num | doskey | command
----------------------------------------
1 | myip | curl https://api.ipify.org
- This script only works on Windows systems.
- Ensure that you run the script with appropriate permissions to modify the registry.
Contributions are welcome! If you have suggestions or improvements, feel free to open an issue or submit a pull request.
This project is licensed under the MIT License. See the LICENSE file for details.