Lets say you are tired of using "sudo apt-get install" again and again , and want to make an alias to it.... simple!
Follow these steps and you'll be good to go
- Go to you home folder and create a file named:
.bash_aliases
(This can also be done via the terminal like so:
touch ~/.bash_aliases
- edit the .bash_aliases file to contain:
- Save the file and open the file named:
.bashrc
Find the section that is commented out (lines preceded with #’s) to looks like this:
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
- Uncomment those lines. Save and close and then open a new terminal window.
Simple ... ain't it? :)
No comments:
Post a Comment