You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

98 lines
1.8 KiB

16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
16 years ago
  1. # ~/.bashrc: executed by bash(1) for non-login shells.
  2. export LANG="en_GB.UTF-8"
  3. # If not running interactively, don't do anything
  4. [ -z "$PS1" ] && return
  5. # GPG
  6. #
  7. x="$HOME/.gpg-agent-info"
  8. if ! type -p gpg-agent > /dev/null; then
  9. rm -f "$x"
  10. elif test -s "$x" &&
  11. kill -0 $(cut -d: -f2 "$x" 2> /dev/null ) 2> /dev/null; then
  12. . "$x"
  13. else
  14. eval $(gpg-agent --daemon --log-file "$HOME/.gpg-agent.log" \
  15. --write-env-file "$x" 2> /dev/null)
  16. fi
  17. if [ -s "$x" ]; then
  18. export GPG_TTY=$(tty)
  19. eval export $(cut -d= -f1 "$x")
  20. fi
  21. unset x
  22. # ssh wrapper
  23. #
  24. if [ -s "$HOME/bin/ssh" ]; then
  25. SSH="$HOME/bin/ssh"
  26. else
  27. SSH=ssh
  28. fi
  29. for x in GIT_SSH; do
  30. eval export $x=$SSH
  31. done
  32. # debian/ubuntu development
  33. #
  34. export DEBFULLNAME="Alejandro Mery"
  35. export DEBEMAIL="amery@geeks.cl"
  36. # other apps chosen by env
  37. #
  38. export BROWSER=links
  39. export EDITOR=vim
  40. # don't put duplicate lines in the history. See bash(1) for more options
  41. # ... or force ignoredups and ignorespace
  42. HISTCONTROL=ignoredups:ignorespace
  43. # append to the history file, don't overwrite it
  44. shopt -s histappend
  45. # for setting history length see HISTSIZE and HISTFILESIZE in bash(1)
  46. HISTSIZE=1000
  47. HISTFILESIZE=2000
  48. # support resize, please
  49. shopt -s checkwinsize
  50. # standarise $TERM
  51. case "$TERM" in
  52. nxterm)
  53. export TERM=xterm
  54. ;;
  55. screen-256color|screen|xterm|rxvt|linux)
  56. ;;
  57. *)
  58. echo "$TERM: Unknown TERM value."
  59. ;;
  60. esac
  61. # get a nicer $PS1
  62. [ -s $HOME/.bash/prompt.in ] && . $HOME/.bash/prompt.in
  63. # aliases
  64. #
  65. alias ls='ls --color=auto'
  66. alias l='ls -avhlF'
  67. alias gdb='gdb -quiet'
  68. [ "$(type -t ll)" = alias ] && unalias ll
  69. function ll() { ls -avhlF $* | less; }
  70. # vi mode
  71. set -o vi
  72. # local settings
  73. for x in .bash/local.in /etc/bash_completion; do
  74. expr "$x" : / > /dev/null || x="$HOME/$x"
  75. if [ -s "$x" ]; then
  76. . "$x"
  77. fi
  78. done