remote-hg: strip extra newline
There's no functional change since mercurial commit operation strips that anyway, but that's no excuse for us not to do the right thing. So let's be explicit about it. Signed-off-by: Felipe Contreras <felipe.contreras@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Felipe Contreras committed
Apr 22, 2013 at 16:55 UTC
160695949a074ae252a4d458a8e135fea3245681
1 file changed
+4
contrib/remote-helpers/git-remote-hg
+4
@@ -652,6 +652,10 @@ def parse_commit(parser):
652
if parser.check('merge'):
653
die('octopus merges are not supported yet')
654
655
+ # fast-export adds an extra newline
656
+ if data[-1] == '\n':
657
+ data = data[:-1]
658
+
659
files = {}
660
661
for line in parser: