[PATCH] subrepo: make sure that the source path is stripped

David Soria Parra sn_ at gmx.net
Sun Feb 14 04:54:47 CST 2010


Am 10.02.10 10:35, schrieb David Soria Parra:
> 
>>>> diff --git a/mercurial/subrepo.py b/mercurial/subrepo.py
>>>> --- a/mercurial/subrepo.py
>>>> +++ b/mercurial/subrepo.py
>>>> @@ -41,7 +41,7 @@
>>>>                 raise util.Abort(_('missing ] in subrepo source'))
>>>>             kind, src = src.split(']', 1)
>>>>             kind = kind[1:]
>>>> -        state[path] = (src, rev.get(path, ''), kind)
>>>> +        state[path] = (src.strip(), rev.get(path, ''), kind)
>>>
>>> What about source paths that start/end with spaces? It seems silly,  
>>> but if nothing else it's worth mentioning in some docs that it won't  
>>> work.
>>
>> This is coming out of the config parser, which already strips?
> In the case
> 
> foo = [git] bar
> 
> the space before bar is not stripped by the parser and I don't think any
> url accepted by subrepos allows spaces.
what's the status of this patch?



More information about the Mercurial-devel mailing list