Hardware Reference
In-Depth Information
This intentional abstraction helps you focus on installation itself and is short,
to keep you away from syntax errors. Most importantly, with this you can set up
your commands toolbox in such a way that whenever you would want to change
to a different distribution, you will still use install package . Here is how you
can do this:
Go and edit your bashrc in the following directory:
~/.bashrc
Here, define some aliases for debian:
alias install="sudo apt-get install"
alias update="sudo apt-get update"
alias search="sudo apt-cache search"
After saving and quitting the editor, you can apply your configuration using the
following command:
debian@beaglebone:~$ source ~/.bashrc
As easy as it can be, you will then just rely on these commands most of the time to
handle your system. In the case, when you use a different package system, you'll just
have to modify accordingly, such as with Fedora:
alias install="yum install"
alias update="yum update"
alias search="yum list"
Get to know what you did previously
Let's keep on personalizing the bashrc file, but this time with the goal being to
look backward for commands that you have already performed.
The aim of this trick is to avoid retyping the same command multiple times.
Moreover, sometimes it's useful to analyze in which order you have executed
different commands, one after the other. This is often the root cause of errors.
This is where histogrep will make your life easier:
function histogrep{
history | grep $1
}
 
Search WWH ::




Custom Search