Originally posted by Robert24
View Post
I find the $PATH variable hard to read, and easy to miss obscure entries. I've been confused by it often over the years. So, now I use an alias, defined in my .bashrc in my home directory:
Code:
$ echo $PATH
/home/john/bin::/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin
$ alias path='echo -e ${PATH//:/\\n}'
$ path
/home/john/bin
/usr/local/sbin
/usr/local/bin
/usr/sbin
/usr/bin
/sbin
/bin
/usr/games
/usr/local/games
/snap/bin
Leave a comment: