-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathbashrc
More file actions
94 lines (76 loc) · 2.65 KB
/
bashrc
File metadata and controls
94 lines (76 loc) · 2.65 KB
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
82
83
84
85
86
87
88
89
90
91
92
93
94
#
# bashrc
#
#if [[ "$TERM" != "screen" ]]
#then
# # try to attach to existing session, or start a new one
# tmux -2 attach-session -t "$USER" || tmux -2 new-session -s "$USER"
# exit
#fi
export HOSTFILE=~/.hosts
export PATH=$PATH:~/bin
unset HISTFILE
HISTCONTROL=ignoredups
EDITOR=vi
VISUAL=vim
PAGER='less -i'
set -o notify # Report status of terminated bg jobs immediately
#set -o emacs # emacs-style editing
#shopt -s extglob # extended pattern matching features
shopt -s cdspell # correct dir spelling errors on cd
shopt -s lithist # save multi-line commands with newlines
shopt -s autocd # if a command is a dir name, cd to it
shopt -s checkjobs # print warning if jobs are running on shell exit
shopt -s dirspell # correct dir spelling errors on completion
shopt -s globstar # ** matches all files, dirs and subdirs
shopt -s cmdhist # save multi-line commands in a single hist entry
shopt -s checkwinsize # check the window size after each command
shopt -s no_empty_cmd_completion # don't try to complete empty cmds
#coloured man pages
export LESS_TERMCAP_mb=$'\E[01;31m'
export LESS_TERMCAP_md=$'\E[01;31m'
export LESS_TERMCAP_me=$'\E[0m'
export LESS_TERMCAP_se=$'\E[0m'
export LESS_TERMCAP_so=$'\E[01;44;33m'
export LESS_TERMCAP_ue=$'\E[0m'
export LESS_TERMCAP_us=$'\E[01;32m'
#export LESSOPEN="|~/bin/lesspipe.sh %s"
# define some colours
GREY=$'\033[1;30m'
RED=$'\033[1;31m'
GREEN=$'\033[1;32m'
YELLOW=$'\033[1;33m'
BLUE=$'\033[1;34m'
MAGENTA=$'\033[1;35m'
CYAN=$'\033[1;36m'
WHITE=$'\033[1;37m'
NONE=$'\033[m'
#random grep color
#export GREP_COLOR="1;3$((RANDOM%6+1))"
#export GREP_OPTIONS='--color=auto'
export GRC_HOME=~/.grc
# colored ant
export ANT_ARGS='-logger org.apache.tools.ant.listener.AnsiColorLogger'
export CDPATH=".::..:../..:~/:~/dev/"
source ~/.dotfiles/prompt
#source ~/.dotfiles/bash_dyncompletion
source ~/.dotfiles/aliases
if [[ -d ~/.dotfiles/functions.d ]]; then
for file in ~/.dotfiles/functions.d/*; do
source "$file"
done
fi
export INPUTRC=~/.dotfiles/inputrc
umask 022
# trap commands and echo them to xterm titlebar. Must be last line.
trap 'echo -ne "\033]0;$BASH_COMMAND - $USER@${HOSTNAME}>$(pwd)\007"' DEBUG
#THIS MUST BE AT THE END OF THE FILE FOR SDKMAN TO WORK!!!
#export SDKMAN_DIR="/home/walo/.sdkman"
#[[ -s "/home/walo/.sdkman/bin/sdkman-init.sh" ]] && source "/home/walo/.sdkman/bin/sdkman-init.sh"
export GOROOT=/opt/go
export GOPATH=~/code_the_web/go/
export PATH=$PATH:$GOROOT/bin
export PATH=$PATH:/opt/bin
export NVM_DIR="$HOME/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion