.zshrc 2.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677
  1. ### O H - M Y - Z S H C O N F I G ###
  2. ## Path to your oh-my-zsh installation.
  3. export ZSH=~/.oh-my-zsh
  4. # Set name of the theme to load.
  5. # Look in ~/.oh-my-zsh/themes/
  6. # Optionally, if you set this to "random", it'll load a random theme each
  7. # time that oh-my-zsh is loaded.
  8. ZSH_THEME="agnoster"
  9. plugins=(git pass brew)
  10. source $ZSH/oh-my-zsh.sh
  11. ### U S E R C O N F I G ###
  12. # Device-specifig setup (ignored by git)
  13. source .zsh-ownrc
  14. ### ALIASES ###
  15. # list directory in human readable (-h), listed (-l) way. Show all files (-a).
  16. # -F: display an indicator for special list entries (folder, links, etc...)
  17. alias ll='ls -Fhla | less -R'
  18. alias l='ls -lha'
  19. # backup-aliases for rsync
  20. alias backup-work-pull='rsync --exclude-from=$WORK/devtool-settings/rsync-exclude --numeric-ids -b --backup-dir=$WORK/.rsync-backup -azuhP uber:~/rsync/arbeit/ $WORK'
  21. alias backup-work-push='rsync --exclude-from=$WORK/devtool-settings/rsync-exclude --numeric-ids -b --backup-dir=.rsync-backup -azuhP $WORK/ uber:~/rsync/arbeit'
  22. alias backup-stud-pull='rsync --exclude-from=$WORK/devtool-settings/rsync-exclude --numeric-ids -b --backup-dir=$STUD/.rsync-backup -azuhP uber:~/rsync/studium/ $STUD'
  23. alias backup-stud-push='rsync --exclude-from=$WORK/devtool-settings/rsync-exclude --numeric-ids -b --backup-dir=.rsync-backup -azuhP $STUD/ uber:~/rsync/studium'
  24. # git aliases
  25. alias gits='git status -s'
  26. # setup ROOT-PATH for python
  27. alias SetupPyROOT='
  28. export LD_LIBRARY_PATH=$ROOTSYS/lib:$PYTHONDIR/lib:$LD_LIBRARY_PATH&&
  29. export PYTHONPATH=$ROOTSYS/lib:$PYTHONPATH'
  30. ### e5-specific ###
  31. alias me5='sshfs lhcb: ~/mount/e5 && cd ~/mount/e5'
  32. # root
  33. alias iwantroot='cd $(brew --prefix root) && source libexec/thisroot.sh'
  34. # rapidminer
  35. alias rapidminer='java -jar -Xmx6G ~/Applications/rapidminer/lib/rapidminer.jar'
  36. ### Users PATHs ###
  37. # Uni
  38. export SMD=~/Documents/Studium/2014\ Wintersemester/SMD/jens-kev/
  39. export STUD=~/Documents/Studium/
  40. export SEM=~/Documents/Studium/2014\ Wintersemester/
  41. export FP=~/Documents/Studium/FP14/
  42. export AP=~/Documents/Studium/AP12/
  43. export PEP=~/Documents/Studium/pep-et-al/
  44. export E5=~/Documents/Studium/e5/
  45. # Work
  46. export WORK=~/Documents/Arbeit/
  47. export FH=~/Documents/Arbeit/2014/ItInvFb9/
  48. # cool extract function
  49. function extract()
  50. {
  51. if [ -f $1 ]; then
  52. case $1 in
  53. *.tar.bz2) tar xvjf $1 ;;
  54. *.tar.gz) tar xvzf $1 ;;
  55. *.tar) tar xvf $1 ;;
  56. *.zip) unzip $1 ;;
  57. *) echo "'$1' cannot be extracted via extract()";;
  58. esac
  59. else
  60. echo "'$1' is not a valid file!"
  61. fi
  62. }