Skip to content

Instantly share code, notes, and snippets.

@dreamerhyde
Created September 4, 2015 16:17
Show Gist options
  • Save dreamerhyde/4befed810f8add882d5c to your computer and use it in GitHub Desktop.
Save dreamerhyde/4befed810f8add882d5c to your computer and use it in GitHub Desktop.
#!/bin/bash
# update libs
sudo apt-get update
sudo apt-get --assume-yes --ignore-missing --reinstall install vim bash-completion
# setting
sudo echo "
export LS_OPTIONS='--color=auto'
eval \`dircolors\`
if [ -f ~/.bash_aliases ]; then
. ~/.bash_aliases
fi
" >> ~/.bashrc
sudo echo "# Alias
alias ls='ls $LS_OPTIONS'
alias ll='ls $LS_OPTIONS -l'
alias l='ls $LS_OPTIONS -lA'
alias ..='cd ..'
alias chwww='chown www-data:www-data -R *'
alias grep='grep --color=auto'
# Drupal
alias d='drush'
alias dcc='drush cache-clear all'
alias dst='drush core-status'
" > ~/.bash_aliases
sudo echo "[color]
ui = true
[alias]
st = status
br = branch
dp = pull origin master
co = checkout
cm = commit
" > ~/.gitconfig
git config --global alias.lg "log --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%C(bold blue) <%an>%Creset' --abbrev-commit"
sudo wget https://gist.githubusercontent.com/dreamerhyde/1e775a5b4efa487b1684/raw/6742588635ed59d2a57a24e640506923f904eae2/twilight256.vim -O /usr/share/vim/vim73/colors/twilight256.vim
sudo echo "syntax on
set t_Co=256
colorscheme twilight256" > /etc/vim/vimrc.local
sudo -s source ~/.bashrc
sudo -s source ~/.bash_aliases
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment