1
0
Fork 0
mirror of https://github.com/ohmyzsh/ohmyzsh.git synced 2024-11-11 00:10:08 +00:00

fix(svn): return true repo name in svn_get_repo_name

This commit is contained in:
Marc Cornellà 2021-12-20 11:22:54 +01:00
parent 75ed59b7c0
commit c76dc91e02
No known key found for this signature in database
GPG key ID: 0314585E776A9C1B

View file

@ -19,10 +19,10 @@ in_svn() {
}
svn_get_repo_name() {
if in_svn; then
LANG=C svn info | sed -n 's/^Repository\ Root:\ .*\///p' | read SVN_ROOT
LANG=C svn info | sed -n "s/^URL:\ .*$SVN_ROOT\///p"
fi
local info name
info="${1:-$(LANG= svn info 2>/dev/null)}"
name="$(sed -n 's/^Repository\ Root:\ .*\///p' <<< "$info")"
omz_urldecode "$name"
}
svn_get_branch_name() {