Skip to content

Instantly share code, notes, and snippets.

@GregLevenhagen
Last active December 1, 2016 02:16
Show Gist options
  • Select an option

  • Save GregLevenhagen/8602a37a1b61333d4b5c7582b4569ff5 to your computer and use it in GitHub Desktop.

Select an option

Save GregLevenhagen/8602a37a1b61333d4b5c7582b4569ff5 to your computer and use it in GitHub Desktop.
macOS .bash_profile
# If not running interactively, don't do anything:
[ -z "$PS1" ] && return
export HISTCONTROL=ignoreboth
export HISTSIZE=100000000000
# enable color support of ls
if [ "$TERM" != "dumb" ]; then
alias ls='ls -GFh'
fi
alias ll='ls -al'
alias rm='rm -i'
alias cp='cp -i'
alias mv='mv -i'
alias more='less'
export PAGER=less
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'
PROMPT="[\[\e[34m\]\u@\h\[\e[0m\]][\[\e[32m\]\w\[\e[0m\]]\n"
if [ $(id -u) -eq 0 ]; then
PS1="${PROMPT}# "
else
PS1="${PROMPT}$ "
fi
export EDITOR=vim
# mysql prompt setting
export MYSQL_PS1="\u@\h [\d]> "
export PAGER=less
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment