My dotfiles. Period.

global-before.bashrc 1.4KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758
  1. #!/bin/bash
  2. #######################################################
  3. ### things to do BEFORE host/user-specific settings ###
  4. #######################################################
  5. ### .... ###
  6. ### SUBZ ###
  7. ### '''' ###
  8. git() {
  9. if grep -Fwqse "$1" "$GIT_DISABLED_COMMANDS"; then
  10. echo "You don't want this." >&2
  11. return 1
  12. else
  13. command git "$@"
  14. fi
  15. }
  16. ### .... ###
  17. ### BASH ###
  18. ### '''' ###
  19. export HISTCONTROL=$HISTCONTROL${HISTCONTROL+:}ignoredups
  20. export HISTIGNORE=$HISTIGNORE:ls:ll:la:cd
  21. export HISTIGNORE="$HISTIGNORE:git ap:git cm:git cma:git dc:git st"
  22. export GLOBIGNORE=.:..
  23. # some more aliases
  24. alias ll='ls -lh'
  25. alias lla='ls -lha'
  26. alias open='gnome-open'
  27. alias diff='diff -u'
  28. alias pad4='sed -e "s/^/ /"'
  29. alias gitka='gitk --all'
  30. alias grepr='grep -nr . -e'
  31. alias sc='se --direction=encz.cz'
  32. ### ...... ###
  33. ### OTHERS ###
  34. ### '''''' ###
  35. export GREP_OPTIONS="--color --binary-files=without-match"
  36. # make green git bash trinket even cooler
  37. export GIT_PS1_SHOWDIRTYSTATE=true
  38. export GIT_PS1_SHOWUNTRACKEDFILES=true
  39. export GIT_DISABLED_COMMANDS="$HOME/.git-universe/disabled-commands"
  40. # disable mounting things like SFTP to ~/.gvfs when accessed
  41. # via GIO (used by nautilus etc.)
  42. export GVFS_DISABLE_FUSE=1
  43. # disable the terrible beep sound (only for X; for tty?, blacklist pcspkr)
  44. [[ ${!DISPLAY[@]} ]] && xset b off
  45. # get rid of those .pyc files once and for all
  46. export PYTHONDONTWRITEBYTECODE=1