chmod 050
.BASHRC
enable color support of ls and also add handy aliases
if [ "$TERM" != "dumb" ]; then
eval "dircolors -b
"
alias ls='ls --color=auto'
#alias dir='ls --color=auto --format=vertical'
#alias vdir='ls --color=auto --format=long'
fi
some more ls aliases
alias ll='ls -la' alias nano='nano -S'
export PATH=$PATH:~/bin
!/bin/bash -x
WHATSINSTALLED.SH
dpkg --get-selections > /bin/date +%Y-%m-%d--%H-%M
-installed-software.txt
-x will display all variables and commands before executing them
!/bin/bash
WHOLAST.SH
who -u echo last | head -n 7
!/bin/bash
TOSCRIPT.SH
chmod 750 $1
Use [[ -v foobar ]] for variables in Bash version >= 4.2.
if [[ -v foobar ]]; then echo "foobar is set, foobar=$foobar" else echo "foobar is not set" fi