03052014 Flashcards
The EDITOR variable can be set to your favorite editor
export EDITOR=/(path)
Prepending a dot to a PATH means the program will be looked for in the current directory first, before searching the rest of the path
export PATH=”.:$PATH”
An export can be removed by setting it to nothing
export EDITOR=
Create simple commands without having to make a script out of it
USING ALIASES
Echo the clear-screen sequence for the current terminal.
tput clear
To remove, use _____ command
unalias
You can also use alias to move around the file system efficiently
e.g.
#example 1
mkdir /home/lezeastmor/linuxbox
alias lbook=”cd /home/lezeastmor/linuxbook”
You can also use alias to move around the file system efficiently ( using variable)
#example 2 export LBOOK="/home/lezeastmor/linuxbook" alias lbook="cd $LBOOK"
You can use the LBOOK variable to copy files to that directory
cd /tmp
touch f1.txt
cp f1.txt $LBOOK
#note that the above examples will only be effective in that terminal and will not persist accross a reboot