mirror of
https://github.com/dcarrillo/prezto.git
synced 2025-06-14 09:51:41 +00:00
Merge branch 'typo' of https://github.com/papercavalier/oh-my-zsh into papercavalier-typo
This commit is contained in:
@ -8,6 +8,7 @@ alias gd='git diff | mate'
|
||||
alias gdv='git diff -w "$@" | vim -R -'
|
||||
alias gc='git commit -v'
|
||||
alias gca='git commit -v -a'
|
||||
alias gco='git checkout'
|
||||
alias gb='git branch'
|
||||
alias gba='git branch -a'
|
||||
alias gcount='git shortlog -sn'
|
||||
@ -26,7 +27,7 @@ function current_branch() {
|
||||
echo ${ref#refs/heads/}
|
||||
}
|
||||
|
||||
# these aliases take advangate of the previous function
|
||||
# these aliases take advantage of the previous function
|
||||
alias ggpull='git pull origin $(current_branch)'
|
||||
alias ggpush='git push origin $(current_branch)'
|
||||
alias ggpnp='git pull origin $(current_branch) && git push origin $(current_branch)'
|
||||
alias ggpnp='git pull origin $(current_branch) && git push origin $(current_branch)'
|
||||
|
8
plugins/rails3/rails3.plugin.zsh
Normal file
8
plugins/rails3/rails3.plugin.zsh
Normal file
@ -0,0 +1,8 @@
|
||||
alias rs='ruby script/rails server'
|
||||
alias rg='ruby script/rails generate'
|
||||
alias rd='ruby script/rails destroy'
|
||||
alias rp='ruby script/rails plugin'
|
||||
alias rdbm='rake db:migrate db:test:clone'
|
||||
alias rc='ruby script/rails console'
|
||||
alias rd='ruby script/rais server --debugger'
|
||||
alias devlog='tail -f log/development.log'
|
42
plugins/svn/svn.plugin.zsh
Normal file
42
plugins/svn/svn.plugin.zsh
Normal file
@ -0,0 +1,42 @@
|
||||
function svn_prompt_info {
|
||||
if [[ -d .svn ]]; then
|
||||
echo "$ZSH_PROMPT_BASE_COLOR$ZSH_THEME_SVN_PROMPT_PREFIX\
|
||||
$ZSH_THEME_REPO_NAME_COLOR$(svn_get_repo_name)$ZSH_PROMPT_BASE_COLOR$ZSH_THEME_SVN_PROMPT_SUFFIX$ZSH_PROMPT_BASE_COLOR$(svn_dirty)$ZSH_PROMPT_BASE_COLOR"
|
||||
fi
|
||||
}
|
||||
|
||||
|
||||
function in_svn() {
|
||||
if [[ -d .svn ]]; then
|
||||
echo 1
|
||||
fi
|
||||
}
|
||||
|
||||
function svn_get_repo_name {
|
||||
if [ is_svn ]; then
|
||||
svn info | sed -n 's/Repository\ Root:\ .*\///p' | read SVN_ROOT
|
||||
|
||||
svn info | sed -n "s/URL:\ .*$SVN_ROOT\///p" | sed "s/\/.*$//"
|
||||
fi
|
||||
}
|
||||
|
||||
function svn_get_rev_nr {
|
||||
if [ is_svn ]; then
|
||||
svn info 2> /dev/null | sed -n s/Revision:\ //p
|
||||
fi
|
||||
}
|
||||
|
||||
function svn_dirty_choose {
|
||||
if [ is_svn ]; then
|
||||
s=$(svn status 2>/dev/null)
|
||||
if [ $s ]; then
|
||||
echo $1
|
||||
else
|
||||
echo $2
|
||||
fi
|
||||
fi
|
||||
}
|
||||
|
||||
function svn_dirty {
|
||||
svn_dirty_choose $ZSH_THEME_SVN_PROMPT_DIRTY $ZSH_THEME_SVN_PROMPT_CLEAN
|
||||
}
|
Reference in New Issue
Block a user