Skip to content

A very basic directory alias manager to quickly navigate to frequently used directories using simple aliases.

License

Notifications You must be signed in to change notification settings

armanossiloko/cd-alias

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

cd-alias

This is a simple directory alias manager that allows you to quickly navigate to frequently used directories using simple aliases.

Building and installing it currently requires .NET 8 SDK.

Installation

  1. Clone the repository:
git clone https://github.com/armanossiloko/cd-alias
  1. In the local repository, make the install.sh script executable:
chmod +x install.sh
  1. Run the script:
./install.sh
  1. Restart your terminal.

Usage

# Show usage information
cda

# Set an alias in Linux:
cda set projects /home/projects

# Or in Windows:
cda set projects "C:\\MyProjects"

# Later on, to navigate to it:
cda projects

# List all aliases
cda list

# Remove an alias
cda remove projects

Configuration

The application stores aliases in a JSON file:

  • Windows: %USERPROFILE%\.cda.json
  • Linux: ~/.cda.json
  • MacOS: ~/.cda.json

An example of what the file could look like:

{
  "projects": "/home/projects",
  "downloads": "/home/user/downloads"
}

Uninstallation

To uninstall cd-alias:

  1. Remove the binary(ies) from:

    • Windows: %USERPROFILE%\.local\bin\cd-alias.exe
    • Linux: ~/.local/bin/cd-alias
    • MacOS: ~/.local/bin/cd-alias
  2. Remove the cda() function from your terminal configuration file.

  3. Remove the aliases store (the .cda.json file) from ~/.cda.json or %USERPROFILE%\.cda.json.

License

This project is licensed under the MIT License - see the LICENSE file for details.

Contributing

I most likely did not cover the majority of use cases or issues that people (if anyone) will run into, so feel free to submit a Pull Request.

Support

If you encounter any issues or have questions, please create a new issue with detailed information about your problem.

About

A very basic directory alias manager to quickly navigate to frequently used directories using simple aliases.

Topics

Resources

License

Stars

Watchers

Forks