Skip to content

Commit

Permalink
allow gitcd to accept a parameter, and add completion
Browse files Browse the repository at this point in the history
Thanks to Thomas Koch for the idea (not sure why I didn't think of this
myself)

http://lists.madduck.net/pipermail/vcs-home/2013-September/000882.html
  • Loading branch information
aspiers committed Sep 16, 2013
1 parent 95310f3 commit 89df1d7
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .zsh/functions/_gitcd
@@ -0,0 +1,3 @@
#compdef gitcd

_path_files -/ -W $(git root)
3 changes: 2 additions & 1 deletion .zsh/functions/gitcd
@@ -1,3 +1,4 @@
#autoload

cd `git root`
root=$( git root )
cd "$root/$1"

0 comments on commit 89df1d7

Please sign in to comment.