Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

how to create a path alias?

Tags:

alias

unix

So "cs" will be mapped to "/College/" so that I can run the command "cd cs"?

like image 617
funk-shun Avatar asked Feb 17 '26 18:02

funk-shun


1 Answers

I believe you are asking about how to create a symbolic link (or symlink) like:

ln -s College cs

Although, there are other ways to speed up your workflow, such as setting the CDPATH:

export CDPATH=.:~/:/College/

Or you could even make "cs" an alias that will perform the action "cd /College/":

alias cs='cd /College/'

If you did the above, you would type cs instead of cd cs to get there.

See also

  • ln - man page for the ln command from the POSIX 2004 standard
  • symlink - man page for the C function to create symlinks from the POSIX 2004 standard
like image 147
Michael Aaron Safyan Avatar answered Feb 21 '26 15:02

Michael Aaron Safyan



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!