[PATCH v2] Remove trailing slash after remove-suffix
Charles Dee Rice
cdrice at pobox.com
Sat Dec 13 20:28:23 CET 2014
Thank you so much for the quick reply!
> The previous version had a flaw (bogus pointer if there is no ".git"
> suffix). This one is much more readable add should be applied on top of
> the Git 2.2.0 patch (which adds strip_suffix() and strip_suffix_mem()).
Version 1 would definitely cause some issues. My brief testing confirmed it could cut off the last letter of the repot name for a bare repo -- "blah.git" became "bla". It did work for non-bare repos, though -- "blah/.git" became "blah" and worked! ;)
Applying the latest version of Christian's git 2.2.0 patch from November + your version 2 looks like it works perfectly!
I now see both bare and non-bare repos working with scanning and remove-suffix enabled. All repo features (refs, log, tree, etc) work correctly in each case.
This really had me scratching my head -- I'm glad to see I wasn't doing something silly after all! Thanks again!
- Chuck
More information about the CGit
mailing list