Skip to content

Instantly share code, notes, and snippets.

@royz
Last active April 8, 2022 19:09
Show Gist options
  • Save royz/cc523d658e9a3388ffcb58de42e468fd to your computer and use it in GitHub Desktop.
Save royz/cc523d658e9a3388ffcb58de42e468fd to your computer and use it in GitHub Desktop.
#!/bin/bash
# enable color support of ls
if [ -x /usr/bin/dircolors ]; then
test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)"
alias ls='ls --color=auto'
alias dir='dir --color=auto'
alias vdir='vdir --color=auto'
alias grep='grep --color=auto'
alias fgrep='fgrep --color=auto'
alias egrep='egrep --color=auto'
fi
# common aliases
alias cls=clear
# load machine specific aliases
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
PS1="\`if [ \$? != 0 ]; then echo \[\e[31m\]\342\234\227\[\e[0m\]; fi\` \[\e[33m\]\w\[\e[36m\]\$(__git_ps1 ' (%s)') \[\e[00m\]\\$ "
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment