Mercurial > dotfiles
changeset 133:5b0b8ad2cb2c
vcs_functions: some versions of the shell don't like - in function names.
author | Augie Fackler <durin42@gmail.com> |
---|---|
date | Tue, 18 Aug 2009 10:13:19 -0500 |
parents | 82fd8ff94de8 |
children | fe9d358b9fe8 |
files | .shell.d/50.vcs_functions.sh |
diffstat | 1 files changed, 10 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/.shell.d/50.vcs_functions.sh +++ b/.shell.d/50.vcs_functions.sh @@ -8,7 +8,7 @@ function mq () { ) } -function ez-svn-sync() { +function ezsvnsync() { local url local repo repo=$1 @@ -20,6 +20,7 @@ function ez-svn-sync() { svnsync init file://`pwd`/$repo $url svnsync sync file://`pwd`/$repo } +alias ez-svn-sync=ezsvnsync # Function to grab the url of an svn wc function svnurlof() { @@ -42,7 +43,7 @@ function svnurlof() { echo $url } -function hg-svn-merge-branch() { +function hgsvnmergebranch() { local targetrev local striprev targetrev=$(hg id | cut -d ' ' -f 1) @@ -53,8 +54,9 @@ function hg-svn-merge-branch() { hg diff -r$targetrev:$striprev | hg import - -m "Merged branch $1." hg strip $striprev } +alias hg-svn-merge-branch=hgsvnmergebranch -function hg-svn-rebase-all() { +function hgsvnrebaseall() { for b in `hg log -u 'Augie Fackler <durin42@gmail.com>' --template '{branches}\n' | sort | uniq` do echo "rebase $b" @@ -71,12 +73,14 @@ function hg-svn-rebase-all() { fi done } +alias hg-svn-rebase-all=hgsvnrebaseall -function hg-ammend() { +function hgamend() { hg qimport -r . && hg qref && hg qfin qtip } +alias hg-amend=hgamend -function hg-svn-mkbranch() { +function hgsvnmkbranch() { local upstream upstream=$(hg paths default | sed 's%/*$%%') local branchname @@ -101,6 +105,7 @@ function hg-svn-mkbranch() { branchname=$br echo svn cp $upstream/$branchname $upstream/branches/$1 } +alias hg-svn-mkbranch=hgsvnmkbranch # Function to clean locks out of svn wcs function clean_svn_source_trees() {