From 870975d4a78cd270a1dab8196166fbebf3a2325c Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 00:12:34 -0400 Subject: [PATCH 01/11] Remove bash stuff --- .bashrc | 65 -------------------------------------------------------- .inputrc | 2 -- .profile | 1 - 3 files changed, 68 deletions(-) delete mode 100755 .bashrc delete mode 100755 .inputrc delete mode 100755 .profile diff --git a/.bashrc b/.bashrc deleted file mode 100755 index a846190..0000000 --- a/.bashrc +++ /dev/null @@ -1,65 +0,0 @@ -# [----------------------------------------------------------------------------] -# [----------------------------- PROMPT ---------------------------------------] -# [----------------------------------------------------------------------------] -hostn=$(hostname -s) -usern=$(whoami) - -function prompt { - ctime=$(date +%T) - prmpt="[${PWD}][${ctime}]" - let FILLS=${COLUMNS}-${#prmpt} - LINE="" - - if [[ "$PWD" =~ "/home/$usern" ]]; then - let FILLS=$FILLS+5+${#usern} - fi - - for (( f=0; f<$FILLS; f++ )) - do - LINE=$LINE"\e[0;34;44m-" - done - - PS1="\e[44;1;37m[\t] \w ${LINE}\e[0m\n" - if [ "$SSH_CONNECTION" == "" ]; then - PS1="$PS1\[\e[1;32;40m\][\u@\h]" - else - PS1="$PS1\[\e[1;33;40m\][\u@\h]" - fi - PS1="$PS1\$(if [ \$? = 0 ]; then echo -e \"\$\"; else echo -e \"\[\e[0;31m\]\$\"; fi)\[\e[0m\] " -} -PROMPT_COMMAND=prompt - -# [----------------------------------------------------------------------------] -# [----------------------------- ALIAS ---------------------------------------] -# [----------------------------------------------------------------------------] - -# Common parameters -alias ls='ls -v --color=auto' -alias ll='ls -lavh' -alias grep='grep --color' - -alias sudo='sudo env PATH=$PATH' - -alias ..='cd ..' -alias ...='cd ../..' -alias ....='cd ../../..' - -# for git -alias get='git' -alias ga='git add' -alias gaa='git add .' -alias gs='git status' -alias gl='git log' -alias gcm='git commit -m' -alias gcf='git commit -F' - -# [----------------------------------------------------------------------------] -# [------------------------------ OTHER ---------------------------------------] -# [----------------------------------------------------------------------------] -# Case insensitive matching -shopt -s nocaseglob - -# [----------------------------------------------------------------------------] -# [------------------------------ PATH ----------------------------------------] -# [----------------------------------------------------------------------------] -PATH=$PATH:$HOME/bin diff --git a/.inputrc b/.inputrc deleted file mode 100755 index 54de828..0000000 --- a/.inputrc +++ /dev/null @@ -1,2 +0,0 @@ -set completion-ignore-case On -TAB: menu-complete diff --git a/.profile b/.profile deleted file mode 100755 index 86795d7..0000000 --- a/.profile +++ /dev/null @@ -1 +0,0 @@ -source ~/.bashrc From f9bcbb39e9d5072c49bd3df7d91286a57723ea7d Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:04:32 -0400 Subject: [PATCH 02/11] Add oh-my-zsh as a git submodule --- .gitmodules | 3 +++ .oh-my-zsh | 1 + .zshrc | 47 +++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 51 insertions(+) create mode 100644 .gitmodules create mode 160000 .oh-my-zsh create mode 100644 .zshrc diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..b66fe48 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule ".oh-my-zsh"] + path = .oh-my-zsh + url = https://github.com/robbyrussell/oh-my-zsh.git diff --git a/.oh-my-zsh b/.oh-my-zsh new file mode 160000 index 0000000..b6ea876 --- /dev/null +++ b/.oh-my-zsh @@ -0,0 +1 @@ +Subproject commit b6ea876971b2270a2c73a07a6f6a337604132c6f diff --git a/.zshrc b/.zshrc new file mode 100644 index 0000000..d4dded7 --- /dev/null +++ b/.zshrc @@ -0,0 +1,47 @@ +# Path to your oh-my-zsh configuration. +ZSH=$HOME/.oh-my-zsh + +# Set name of the theme to load. +# Look in ~/.oh-my-zsh/themes/ +# Optionally, if you set this to "random", it'll load a random theme each +# time that oh-my-zsh is loaded. +ZSH_THEME="robbyrussell" + +# Example aliases +# alias zshconfig="mate ~/.zshrc" +# alias ohmyzsh="mate ~/.oh-my-zsh" + +# Set to this to use case-sensitive completion +# CASE_SENSITIVE="true" + +# Comment this out to disable bi-weekly auto-update checks +# DISABLE_AUTO_UPDATE="true" + +# Uncomment to change how often before auto-updates occur? (in days) +# export UPDATE_ZSH_DAYS=13 + +# Uncomment following line if you want to disable colors in ls +# DISABLE_LS_COLORS="true" + +# Uncomment following line if you want to disable autosetting terminal title. +# DISABLE_AUTO_TITLE="true" + +# Uncomment following line if you want to disable command autocorrection +# DISABLE_CORRECTION="true" + +# Uncomment following line if you want red dots to be displayed while waiting for completion +# COMPLETION_WAITING_DOTS="true" + +# Uncomment following line if you want to disable marking untracked files under +# VCS as dirty. This makes repository status check for large repositories much, +# much faster. +# DISABLE_UNTRACKED_FILES_DIRTY="true" + +# Which plugins would you like to load? (plugins can be found in ~/.oh-my-zsh/plugins/*) +# Custom plugins may be added to ~/.oh-my-zsh/custom/plugins/ +# Example format: plugins=(rails git textmate ruby lighthouse) +plugins=(git) + +source $ZSH/oh-my-zsh.sh + +# Customize to your needs... From 67cdb5a0f0020943d8e287c63a97eefcf714dfef Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:10:47 -0400 Subject: [PATCH 03/11] List directory when changing --- .zshrc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.zshrc b/.zshrc index d4dded7..5335d16 100644 --- a/.zshrc +++ b/.zshrc @@ -7,6 +7,10 @@ ZSH=$HOME/.oh-my-zsh # time that oh-my-zsh is loaded. ZSH_THEME="robbyrussell" +# List directory when changing (github/r00k) +chpwd() { + ls -lvh --color=auto +} # Example aliases # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" From 86c4d7c2a0c972799ce8d5c78aa48ae9f4c7565b Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:12:02 -0400 Subject: [PATCH 04/11] Update history length --- .zshrc | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.zshrc b/.zshrc index 5335d16..1bdeb52 100644 --- a/.zshrc +++ b/.zshrc @@ -11,6 +11,12 @@ ZSH_THEME="robbyrussell" chpwd() { ls -lvh --color=auto } + +# Larger history +HISTSIZE=10000 +HISTFILE=~/.zsh_history +SAVEHIST=10000 + # Example aliases # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" From 7526e728f47f1940c50338776d81094b2ebcdd49 Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:14:37 -0400 Subject: [PATCH 05/11] Other initial setup --- .aliases | 0 .zshrc | 6 ++++++ 2 files changed, 6 insertions(+) create mode 100644 .aliases diff --git a/.aliases b/.aliases new file mode 100644 index 0000000..e69de29 diff --git a/.zshrc b/.zshrc index 1bdeb52..3f875c8 100644 --- a/.zshrc +++ b/.zshrc @@ -54,4 +54,10 @@ plugins=(git) source $ZSH/oh-my-zsh.sh +# Aliases file +source $HOME/.aliases + +# Add personal bin folder +PATH=$PATH:$HOME/bin + # Customize to your needs... From 86f0ec3b8bbc5e137beaeb072b7e9e96fd9ace49 Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:15:58 -0400 Subject: [PATCH 06/11] Add git aliases --- .aliases | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/.aliases b/.aliases index e69de29..30429a2 100644 --- a/.aliases +++ b/.aliases @@ -0,0 +1,6 @@ +alias gcm="git commit -m" +alias gs="git status" +alias gaa="git add ." +alias ga="git add" +alias gl="git log" +alias grm="git rm" From 389e8afde980324babf1375d26b6b773f798959d Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:18:39 -0400 Subject: [PATCH 07/11] Add alias for Source directory --- .aliases | 1 + 1 file changed, 1 insertion(+) diff --git a/.aliases b/.aliases index 30429a2..3122921 100644 --- a/.aliases +++ b/.aliases @@ -4,3 +4,4 @@ alias gaa="git add ." alias ga="git add" alias gl="git log" alias grm="git rm" +alias s="cd ~/Source" From 22dae53c75d6d6968e112450dccfb12f1f6ddc06 Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:25:52 -0400 Subject: [PATCH 08/11] Update aliases with more frequent uses --- .aliases | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/.aliases b/.aliases index 3122921..7433394 100644 --- a/.aliases +++ b/.aliases @@ -1,7 +1,11 @@ +alias a="ls -la" +alias al="zsh_stats" alias gcm="git commit -m" alias gs="git status" alias gaa="git add ." alias ga="git add" alias gl="git log" alias grm="git rm" +alias l="ls -lvh --color=auto" alias s="cd ~/Source" +alias v="vim" From 495c21a819afa04bf5a08778d553898076a990cf Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 01:29:01 -0400 Subject: [PATCH 09/11] gitconfig fix --- .gitconfig | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.gitconfig b/.gitconfig index e5f15e1..e09bbcc 100644 --- a/.gitconfig +++ b/.gitconfig @@ -24,4 +24,6 @@ excludesfile = ~/.gitignore_global autocrlf = input editor = subl - filemode = false \ No newline at end of file + filemode = false +[push] + default = upstream From 2d1f20e9226550b0e737b466fa962a96b967e511 Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 02:16:39 -0400 Subject: [PATCH 10/11] Update git settings --- .aliases | 8 +++++--- .gitconfig | 19 ++++++++++++------- 2 files changed, 17 insertions(+), 10 deletions(-) diff --git a/.aliases b/.aliases index 7433394..adb25aa 100644 --- a/.aliases +++ b/.aliases @@ -1,11 +1,13 @@ alias a="ls -la" alias al="zsh_stats" -alias gcm="git commit -m" -alias gs="git status" -alias gaa="git add ." alias ga="git add" +alias gaa="git add ." +alias gcm="git commit -m" +alias gd="git diff" alias gl="git log" +alias gh="git hist" alias grm="git rm" +alias gs="git status" alias l="ls -lvh --color=auto" alias s="cd ~/Source" alias v="vim" diff --git a/.gitconfig b/.gitconfig index e09bbcc..07a102a 100644 --- a/.gitconfig +++ b/.gitconfig @@ -1,6 +1,13 @@ [user] - name = Andrew Tomaka - email = atomaka@gmail.com + name = Andrew Tomaka + email = atomaka@gmail.com +[github] + user = atomaka + +[apply] + whitespace = fix +[alias] + hist = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr)%Creset' --abbrev-commit --date=relative [color] ui = auto [color "branch"] @@ -16,14 +23,12 @@ added = yellow changed = green untracked = cyan -[merge] - tool = vimdiff -[apply] - whitespace = fix -[core] +[core] excludesfile = ~/.gitignore_global autocrlf = input editor = subl filemode = false +[merge] + tool = vimdiff [push] default = upstream From 7124b11fe01bccd0079a609317da6689afad7293 Mon Sep 17 00:00:00 2001 From: Andrew Tomaka Date: Mon, 29 Apr 2013 02:31:18 -0400 Subject: [PATCH 11/11] Start vim config --- .vimrc | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .vimrc diff --git a/.vimrc b/.vimrc new file mode 100644 index 0000000..374f961 --- /dev/null +++ b/.vimrc @@ -0,0 +1,27 @@ +" Options +set nocompatible " Disable vi compatibility +set ffs=unix,dos " File format prefer unix endings +set eol " Add newlien at end of file +set shellslash " Forward slashes +set nobk " No backup files +set textwidth=80 +set laststatus=2 " Always show status line +set showmode " Show current mode +set history=100 " History length +set cul " Highlight current line +set nowrap " Disable wrapping by default +set backspace=2 " Backspace over indent, eol, start of insert +set hlsearch " Search highlights +set wrapscan " Wraped search +set incsearch " Search as yuo type +set ignorecase " Ignore case with search +set smartcase " Search will not ignore uppercase +set showcmd " Show command as you type +set hls " Highlight search (hlsearch?) +set ruler " Show cursor position +set autoindent +" Tabs are 2 spaces +set tabstop=2 +set softtabstop=2 +set shiftwidth=2 +set expandtab