Merge pull request #4 from aried3r/master

Fixed a bug related to sanitizing branch names.
This commit is contained in:
frej
2012-05-20 10:31:40 -07:00

View File

@@ -140,7 +140,7 @@ def sanitize_name(name,what="branch"):
n=name
p=re.compile('([[ ~^:?*]|\.\.)')
n=p.sub('_', n)
if n[-1] == '/': n=n[:-1]+'_'
if n[-1] in ('/', '.'): n=n[:-1]+'_'
n='/'.join(map(dot,n.split('/')))
p=re.compile('_+')
n=p.sub('_', n)