Skip to content

Mac #1

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 7 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .bash_profile
Original file line number Diff line number Diff line change
@@ -1,2 +1 @@
source ~/.bashrc
export PYTHONPATH="/usr/local/lib/python2.7/site-packages:$PYTHONPATH"
31 changes: 25 additions & 6 deletions .bashrc
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ function git_branch {
echo "("${ref#refs/heads/}") ";
}

# shot git last commit
# show git last commit
function git_since_last_commit {
now=`date +%s`;
last_commit=$(git log --pretty=format:%at -1 2> /dev/null) || return;
Expand All @@ -119,7 +119,15 @@ function git_since_last_commit {
echo "${hours_since_last_commit}h${minutes_since_last_commit}m ";
}

PS1="[\[\033[1;32m\]\w\[\033[0m\]] \[\033[0m\]\[\033[1;36m\]\$(git_branch)\[\033[0;33m\]\$(git_since_last_commit)\[\033[0m\]$ "
# show file in the directory
function file_of_dir {
file_num=$(/bin/ls -1 | /usr/bin/wc -l | /usr/bin/sed 's: ::g')
file_size=$(/bin/ls -lahsk | /usr/bin/grep -m 1 total | /usr/bin/sed 's/total //')
echo "${file_num} files, ${file_size}K";
}

PS1="\033[1;35m\]\u\033[0m\]@\033[1;36m\]\h\033[0m\][\033[1;32m\]\w\[\033[0m\]] \$(file_of_dir)
\[\033[0m\]\[\033[1;36m\]\$(git_branch)\[\033[0;33m\]\$(git_since_last_commit)\[\033[0m\]$ "

export PYTHONPATH=${PYTHONPATH}

Expand Down Expand Up @@ -154,16 +162,27 @@ PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for script
PATH=$PATH:/usr/local/share/python # Add for mac python script
[[ -s "$HOME/.rvm/scripts/rvm" ]] && . "$HOME/.rvm/scripts/rvm" # Load RVM function

export WORKON_HOME=$HOME/Envs
export PROJECT_HOME=$HOME/Devel
#export WORKON_HOME=$HOME/Envs
#export PROJECT_HOME=$HOME/Devel
#source ~/python_env/bin/virtualenvwrapper.sh
source ~/python_env/bin/activate
export PIP_REQUIRE_VIRTUALENV=true
#source ~/python_env/bin/activate
#source /usr/local/share/python/virtualenvwrapper.sh
#export PIP_REQUIRE_VIRTUALENV=true
#for python virtualenv
export WORKON_HOME=$HOME/.virtualenv
export PROJECT_HOME=$HOME/mydev
export VIRTUALENVWRAPPER_SCRIPT=/usr/local/share/python/virtualenvwrapper.sh
source /usr/local/share/python/virtualenvwrapper_lazy.sh

if [ -f ~/.git-completion.bash ]; then
. ~/.git-completion.bash
fi

export EDITOR='vim'
export PATH="$(brew --prefix)/bin:$PATH"
#for aws
export PATH=$PATH:/Users/jslee/mydev/eb/eb/linux/python2.7/
#export PYTHONPATH="/usr/local/lib/python2.7/site-packages:$PYTHONPATH"

export PAGER="most"
PATH="/usr/local/bin:/usr/local/sbin:$PATH"
48 changes: 48 additions & 0 deletions .zshrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# 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"

# Uncomment this 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...
PATH="/usr/local/bin:/usr/local/sbin:$PATH"
2 changes: 2 additions & 0 deletions auto-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ function LinkIt() {
fi
else
ln -s "$INSTALL_TO/MyDotFiles/$1" "$HOME/$1"
echo "link $1 done"
fi
}

Expand All @@ -47,6 +48,7 @@ LinkIt .bash
LinkIt .gemrc
LinkIt .git-completion.bash
LinkIt .tmux.conf
LinkIt .zshrc

echo "Installed and configured, have fun."