set alias command in bash profile a dir code example
Example 1: bash how to set up aliases
1. Open the .bashrc file with your favorite shell text editor. E.g.
type "vi ~/.bashrc"
2. Define an alias on a new line using this basic syntax:
alias abbreviated_command='original -long -command'
E.g.: alias ls='ls --color -lhAFG'
3. Save and exit the .bashrc file (e.g. type ":q" and Enter in vi/vim)
4. Source the .bashrc file to apply/activate the alias. E.g.
type "source ~/.bashrc"
alias bashrc='vi ~/.bashrc'
alias sourcebash='source ~/.bashrc'
Example 2: bash profile alias
alias e=exit
alias c=clear
alias r=reset
alias jn=jupyter-notebook
alias python=python3.7