robbyrussell/oh-my-zsh — Issue #814: svn plugin does not urldecode
Author: cprussin
Created: 2012-01-06 18:26:02+00:00
State: open

As the title says, the SVN plugin sometimes ends up with %20s and other url characters. A quick fix is:

diff --git a/plugins/svn/svn.plugin.zsh b/plugins/svn/svn.plugin.zsh
index e2cf96c..5b6fda1 100644
--- a/plugins/svn/svn.plugin.zsh
+++ b/plugins/svn/svn.plugin.zsh
@@ -16,7 +16,7 @@ function svn_get_repo_name {
if [ $(in_svn) ]; then
svn info | sed -n 's/Repository\ Root:\ .*\///p' | read SVN_ROOT

- svn info | sed -n "s/URL:\ .*$SVN_ROOT\///p" | sed "s/\/.*$//"
+ svn info | sed -n "s/URL:\ .*$SVN_ROOT\///p" | sed "s/\/.*$//" | sed -e's/%\([0-9A-F][0-9A-F]\)/\\\\\x\1/g' | xargs echo -e
fi
}