Last active
January 3, 2017 03:33
-
-
Save zfz/10232384 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # For Linux Bash | |
| # Source global definitions | |
| if [ -f /etc/bashrc ]; then | |
| . /etc/bashrc | |
| fi | |
| # Color Scheme | |
| export CLICOLOR=1 | |
| export LSCOLORS=GxFxCxDxBxegedabagaced | |
| # Centos | |
| source /etc/bash_completion.d/git | |
| # Ubuntu | |
| #source /etc/bash_completion.d/git-prompt | |
| #alias ls="ls --color=auto" | |
| #alias ll="ls -al --color=auto" | |
| export GIT_PS1_SHOWDIRTYSTATE=1 | |
| D=$'\e[37;40m' | |
| BLUE="\[\033[0;34m\]" | |
| PINK=$'\e[35;40m' | |
| GREEN=$'\e[32;39m' | |
| ORANGE=$'\e[33;40m' | |
| CYCAN=$'\e[0;36m' | |
| export PS1="\n${D}\u${D}@${PINK}\h${D} ${D}\w${ORANGE}\$(__git_ps1)\ | |
| ${GREEN}\n$ " | |
| # User specific aliases and functions | |
| # Log every command typed and when | |
| if [ -n "${BASH_VERSION}" ]; then | |
| trap "caller >/dev/null || \ | |
| printf '%s\\n' \"\$(date '+%Y-%m-%dT%H:%M:%S%z')\ | |
| \$(tty) \${BASH_COMMAND}\" 2>/dev/null >>~/.command_log" DEBUG | |
| fi | |
| # Autocomplete hostnames for ssh and scp, hostnames are stored in ~/.ssh/complete_hosts | |
| complete -W "$(echo $(cat ~/.ssh/complete_hosts | sort -u ))" ssh scp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment