1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 | complete -cf sudo
complete -cf man
# Bash completion
set show-all-if-ambiguous on
# Check for an interactive session
[ -z "$PS1" ] && return
GREEN='\e[0;32m'
GRAY='\e[0;38m'
GRAYBOLD='\e[1;38m'
PS1=$GRAYBOLD'[\u@\h \W]\$ '$GRAY
#export PS1='\[\033\h \W\$ \[\033[0;38m\]'
# my aliases
alias TODO='mousepad ~/.xnots/TODO'
alias rm='rm -i -v'
alias cp='cp -i -v'
alias mv='mv -i -v'
alias sudo="sudo -E"
alias tarbz2="tar jxf"
alias targz="tar xzvf"
alias tarbz="tar -xjf"
alias bz2="bunzip2"
#alias rar="unrar x"
alias tar_normal="tar xvf"
alias tbz2="tar jxvf"
alias tgz="tar xzf"
#alias zip="tar zxf"
alias grep='grep --color=auto'
alias ls='ls --color=auto'
export EDITOR=nano
export VISUAL=nano
export BROWSER=chromium
# proxy uminho
# receives 1 parameter: 0 or 1 (off or on)
function proxy_um {
if [ "$1" = 0 ]; then
echo "Proxy OFF"
http_proxy=""
socks_proxy=""
elif [ "$1" = 1 ]; then
echo "Proxy ON"
http_proxy="http://proxy.uminho.pt:3128"
socks_proxy="http://socks.uminho.pt:1080"
else
echo "You have to pass on integer argument: 0 (off) or 1 (on)"
fi
export http_proxy=$http_proxy
export https_proxy=$http_proxy
export socks_proxy=$socks_proxy
export SOCKS_SERVER=$socks_proxy
export ftp_proxy=$http_proxy
export all_proxy=$http_proxy
}
#java
#export "_JAVA_AWT_WM_NONREPARENTING=1"
#export _JAVA_OPTIONS="-Dswing.aatext=true"
#export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on"
export _JAVA_OPTIONS="-Dawt.useSystemAAFontSettings=on -Dswing.defaultlaf=com.sun.java.swing.plaf.gtk.GTKLookAndFeel"
# ssh asus n61
alias sshAsusN61Passphrase='echo "0BA73792FBB156774EFF6C478E9A045B76601CDC0426F8A1232580D23A41A9A9"'
alias sshAsusN61='ssh -p 74 nc@74nc-laptop'
# startx
alias startx='echo -e "Use xinit instead of startx!\\nto execute a WM do: $ xinit WM_name"'
# xinit
alias xinit='xinit -nolisten tcp'
#lan
alias wirelessMap='echo "nmap -sP 192.168.1.1-255"'
# sicstus
alias sicstus='rlwrap sicstus'
|
x