{"thread":{"id":"33979","subject":"t0008-ignores failure (was: Git for Windows 1.8.3)","startedAt":"2013-05-30T01:13:27Z","lastAt":"2013-05-30T17:14:55Z","messageCount":8,"participants":["Karsten Blees","Junio C Hamano","Jeff King","Johannes Sixt","Johannes Schindelin","Pat Thoyts"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"218917","messageId":"51A6A7B7.4010802@gmail.com","threadId":"33979","inReplyTo":"CABNJ2G+u96P+_=Q7it0KbK9E01qunz7XZ7e3zCZvaTaOUuTQqQ@mail.gmail.com","subject":"t0008-ignores failure (was: Git for Windows 1.8.3)","fromName":"Karsten Blees","fromEmail":"karsten.blees@gmail.com","sentAt":"2013-05-30T01:13:27Z","receivedAt":"2013-05-30T01:13:27Z","isPatch":false,"sender":{"key":"karsten.blees@gmail.com","avatar":"https://avatars.githubusercontent.com/u/1111200?v=4"},"body":"Am 25.05.2013 21:16, schrieb Pat Thoyts:\n> On that note -- with this merge as it now stands I get the following\n> test failures:\n> \n> t0008-ignores.sh                     155, 158, 162, 164\n\nThese tests fail because they use absolute paths, e.g. \"C:/.../global-excludes\", which is then translated to \"C<NUL>/.../global-excludes\". Can be fixed like so:\n\n--- 8< ---\n--- a/t/t0008-ignores.sh\n+++ b/t/t0008-ignores.sh\n@@ -5,7 +5,7 @@ test_description=check-ignore\n . ./test-lib.sh\n\n init_vars () {\n-       global_excludes=\"$(pwd)/global-excludes\"\n+       global_excludes=\"global-excludes\"\n }\n\n enable_global_excludes () {\n---\n\nHowever, this raises the question whether colon is such a good choice as separator in 'git-check-ignore --verbose' output.\n\n':' conflicts at least with Windows absolute paths and ADS names, and also with URLs (in case someone finds 'git ls-files --exclude-from=http://git-tricks.foo/special-exclude-file' useful enough to implement :-)\n\nI realize colon was chosen to mimic git-check-attr, however, check-attr prints relative paths only (I think?).\n\nHow about using TAB or '|' instead? AFAICT, these are typically not used in paths or glob patterns.\n\nCheers,\nKarsten\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"218919","messageId":"7vzjvdp5q8.fsf@alter.siamese.dyndns.org","threadId":"33979","inReplyTo":"51A6A7B7.4010802@gmail.com","subject":"Re: t0008-ignores failure","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2013-05-30T02:21:51Z","receivedAt":"2013-05-30T02:21:51Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Karsten Blees <karsten.blees@gmail.com> writes:\n\n> I realize colon was chosen to mimic git-check-attr, however,\n> check-attr prints relative paths only (I think?).\n>\n> How about using TAB or '|' instead? AFAICT, these are typically\n> not used in paths or glob patterns.\n\nThe primary reason to use ':' in \"check-ignore -v\" is to mimic the\noutput format of \"grep -n\".\n\nEmacs users can then run the commands like check-attr/check-ignore\nwith \"M-x find-grep\" (or \"M-x compile\"), the output format is\nrecognized by the editor, and the user can jump around with \\C-x` to\nview hits.\n\nI do not use vim myself, but I would be mildly surprised if there\nisn't a similar feature there.\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"218925","messageId":"20130530025258.GB19860@sigill.intra.peff.net","threadId":"33979","inReplyTo":"7vzjvdp5q8.fsf@alter.siamese.dyndns.org","subject":"Re: t0008-ignores failure","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2013-05-30T02:52:58Z","receivedAt":"2013-05-30T02:52:58Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Wed, May 29, 2013 at 07:21:51PM -0700, Junio C Hamano wrote:\n\n> Karsten Blees <karsten.blees@gmail.com> writes:\n> \n> > I realize colon was chosen to mimic git-check-attr, however,\n> > check-attr prints relative paths only (I think?).\n> >\n> > How about using TAB or '|' instead? AFAICT, these are typically\n> > not used in paths or glob patterns.\n> \n> The primary reason to use ':' in \"check-ignore -v\" is to mimic the\n> output format of \"grep -n\".\n> \n> Emacs users can then run the commands like check-attr/check-ignore\n> with \"M-x find-grep\" (or \"M-x compile\"), the output format is\n> recognized by the editor, and the user can jump around with \\C-x` to\n> view hits.\n> \n> I do not use vim myself, but I would be mildly surprised if there\n> isn't a similar feature there.\n\nIt does (it is how my \"git jump\" command feeds marks to vim). Usually we\nwould quote ambiguous pathnames, but I think we do not here to retain\ncompatibility with that microformat. Readers that care about quoting\nshould use \"-z\" to get unambiguous output. And indeed, it seems that\ncheck-ignore behaves reasonably in this case. The tests fail because the\ntest script itself is lazy. It does:\n\n  sed -e 's/      \"/      /' -e 's/\\\\//' -e 's/\"$//' expected-verbose | \\\n        tr \":\\t\\n\" \"\\0\" >expected-verbose0\n\nwhich generates a bogus expectation; both the delimiter colons and any\nin the fields are converted, whereas only the former should be.\nKarsten's fix should work, or we could generate our expected output more\ncarefully.\n\nLong ago we switched to putting a space into our trash directory name to\ncatch problems with such pathnames when we run the test suite. I wonder\nif we should do the same with \":\". Doing this:\n\ndiff --git a/t/test-lib.sh b/t/test-lib.sh\nindex ca6bdef..5d84705 100644\n--- a/t/test-lib.sh\n+++ b/t/test-lib.sh\n@@ -600,7 +600,7 @@ fi\n fi\n \n # Test repository\n-TRASH_DIRECTORY=\"trash directory.$(basename \"$0\" .sh)\"\n+TRASH_DIRECTORY=\"trash directory:$(basename \"$0\" .sh)\"\n test -n \"$root\" && TRASH_DIRECTORY=\"$root/$TRASH_DIRECTORY\"\n case \"$TRASH_DIRECTORY\" in\n /*) ;; # absolute path is good\n\nreveals the breakage on Linux. And it seems that a lot of other tests\nbreak, too. I haven't looked into them yet, though.\n\n-Peff\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"218926","messageId":"20130530025554.GC19860@sigill.intra.peff.net","threadId":"33979","inReplyTo":"20130530025258.GB19860@sigill.intra.peff.net","subject":"Re: t0008-ignores failure","fromName":"Jeff King","fromEmail":"peff@peff.net","sentAt":"2013-05-30T02:55:54Z","receivedAt":"2013-05-30T02:55:54Z","isPatch":false,"sender":{"key":"peff@peff.net","avatar":"https://avatars.githubusercontent.com/u/45925?v=4"},"body":"On Wed, May 29, 2013 at 10:52:58PM -0400, Jeff King wrote:\n\n> diff --git a/t/test-lib.sh b/t/test-lib.sh\n> index ca6bdef..5d84705 100644\n> --- a/t/test-lib.sh\n> +++ b/t/test-lib.sh\n> @@ -600,7 +600,7 @@ fi\n>  fi\n>  \n>  # Test repository\n> -TRASH_DIRECTORY=\"trash directory.$(basename \"$0\" .sh)\"\n> +TRASH_DIRECTORY=\"trash directory:$(basename \"$0\" .sh)\"\n>  test -n \"$root\" && TRASH_DIRECTORY=\"$root/$TRASH_DIRECTORY\"\n>  case \"$TRASH_DIRECTORY\" in\n>  /*) ;; # absolute path is good\n> \n> reveals the breakage on Linux. And it seems that a lot of other tests\n> break, too. I haven't looked into them yet, though.\n\nHrm. Just picking an example at random, t7006 fails because it uses\n--exec-path=\"`pwd`\". And of course colons are meaningful in any\nPATH-like context. It would be nice to be able to handle that case\ncleanly, but I think we would be breaking compatibility.\n\nSo while it would be nice to work on paths with colons everywhere, I\ndoubt it is worth the effort to start checking it through the whole test\nsuite.\n\n-Peff\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"218944","messageId":"51A6F889.9030205@kdbg.org","threadId":"33979","inReplyTo":"20130530025554.GC19860@sigill.intra.peff.net","subject":"Re: Re: t0008-ignores failure","fromName":"Johannes Sixt","fromEmail":"j6t@kdbg.org","sentAt":"2013-05-30T06:58:17Z","receivedAt":"2013-05-30T06:58:17Z","isPatch":false,"sender":{"key":"j6t@kdbg.org","avatar":"https://avatars.githubusercontent.com/u/14810926?v=4"},"body":"Am 30.05.2013 04:55, schrieb Jeff King:\n> So while it would be nice to work on paths with colons everywhere, I\n> doubt it is worth the effort to start checking it through the whole test\n> suite.\n\nAnd on top of it, on Windows, you can't have a path component or file\nname that contains a colon...\n\n-- Hannes\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"219019","messageId":"alpine.DEB.1.00.1305301713400.650@s15462909.onlinehome-server.info","threadId":"33979","inReplyTo":"51A6A7B7.4010802@gmail.com","subject":"Re: t0008-ignores failure (was: Git for Windows 1.8.3)","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2013-05-30T15:15:07Z","receivedAt":"2013-05-30T15:15:07Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi Karsten,\n\nOn Thu, 30 May 2013, Karsten Blees wrote:\n\n> Am 25.05.2013 21:16, schrieb Pat Thoyts:\n> > On that note -- with this merge as it now stands I get the following\n> > test failures:\n> > \n> > t0008-ignores.sh                     155, 158, 162, 164\n> \n> These tests fail because they use absolute paths, e.g. \"C:/.../global-excludes\", which is then translated to \"C<NUL>/.../global-excludes\". Can be fixed like so:\n> \n> --- 8< ---\n> --- a/t/t0008-ignores.sh\n> +++ b/t/t0008-ignores.sh\n> @@ -5,7 +5,7 @@ test_description=check-ignore\n>  . ./test-lib.sh\n> \n>  init_vars () {\n> -       global_excludes=\"$(pwd)/global-excludes\"\n> +       global_excludes=\"global-excludes\"\n>  }\n> \n>  enable_global_excludes () {\n> ---\n\nSince I do not have time for the lengthy, undirected discussion upstream\nseems to want to start, let's make your change, but only conditional on\nMINGW?\n\nCiao,\nDscho\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"219024","messageId":"CABNJ2GKPvbYFgqGL-g3Pnp7OghpoSfeuPEF0vNHixhQFkY+Uow@mail.gmail.com","threadId":"33979","inReplyTo":"alpine.DEB.1.00.1305301713400.650@s15462909.onlinehome-server.info","subject":"Re: t0008-ignores failure (was: Git for Windows 1.8.3)","fromName":"Pat Thoyts","fromEmail":"patthoyts@gmail.com","sentAt":"2013-05-30T15:45:58Z","receivedAt":"2013-05-30T15:45:58Z","isPatch":false,"sender":{"key":"patthoyts@gmail.com","avatar":"https://gravatar.com/avatar/bee887a777c790bd241f398217723fbe4b854428671db83db32216a28654cb25?d=mp&s=160"},"body":"On 30 May 2013 16:15, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n> Hi Karsten,\n>\n> On Thu, 30 May 2013, Karsten Blees wrote:\n>\n>> Am 25.05.2013 21:16, schrieb Pat Thoyts:\n>> > On that note -- with this merge as it now stands I get the following\n>> > test failures:\n>> >\n>> > t0008-ignores.sh                     155, 158, 162, 164\n>>\n>> These tests fail because they use absolute paths, e.g. \"C:/.../global-excludes\", which is then translated to \"C<NUL>/.../global-excludes\". Can be fixed like so:\n>>\n>> --- 8< ---\n>> --- a/t/t0008-ignores.sh\n>> +++ b/t/t0008-ignores.sh\n>> @@ -5,7 +5,7 @@ test_description=check-ignore\n>>  . ./test-lib.sh\n>>\n>>  init_vars () {\n>> -       global_excludes=\"$(pwd)/global-excludes\"\n>> +       global_excludes=\"global-excludes\"\n>>  }\n>>\n>>  enable_global_excludes () {\n>> ---\n>\n> Since I do not have time for the lengthy, undirected discussion upstream\n> seems to want to start, let's make your change, but only conditional on\n> MINGW?\n>\n> Ciao,\n> Dscho\n\nI was just testing this -- I've already wrapped the suggested fix\nwithin a \"test_have_prereq MINGW\" for our fork and committed it. This\nwas  an issue partly because was alias pwd to \"pwd -W\" and so always\nget Windows paths. It means the test here doesn't check absolute paths\nbut I think we can live with that. I tried using $(builtin pwd) to\navoid the \"-W\" but it didn't help and I still got C: style paths.\n\nI also grabbed Karsten's patch \"dir.c: fix ignore processing within\nnot-ignored directories\" as this appears to deal with a .gitignore\nregression in 1.8.3. We can carry this until the next merge with\nupstream.\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"},{"id":"219036","messageId":"alpine.DEB.1.00.1305301914290.650@s15462909.onlinehome-server.info","threadId":"33979","inReplyTo":"CABNJ2GKPvbYFgqGL-g3Pnp7OghpoSfeuPEF0vNHixhQFkY+Uow@mail.gmail.com","subject":"Re: t0008-ignores failure (was: Git for Windows 1.8.3)","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2013-05-30T17:14:55Z","receivedAt":"2013-05-30T17:14:55Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi Pat,\n\nOn Thu, 30 May 2013, Pat Thoyts wrote:\n\n> On 30 May 2013 16:15, Johannes Schindelin <Johannes.Schindelin@gmx.de> wrote:\n>\n> > On Thu, 30 May 2013, Karsten Blees wrote:\n> >\n> >> Am 25.05.2013 21:16, schrieb Pat Thoyts:\n> >> > On that note -- with this merge as it now stands I get the following\n> >> > test failures:\n> >> >\n> >> > t0008-ignores.sh                     155, 158, 162, 164\n> >>\n> >> These tests fail because they use absolute paths, e.g.\n> >> \"C:/.../global-excludes\", which is then translated to\n> >> \"C<NUL>/.../global-excludes\". Can be fixed like so:\n> >>\n> >> --- 8< ---\n> >> --- a/t/t0008-ignores.sh\n> >> +++ b/t/t0008-ignores.sh\n> >> @@ -5,7 +5,7 @@ test_description=check-ignore\n> >>  . ./test-lib.sh\n> >>\n> >>  init_vars () {\n> >> -       global_excludes=\"$(pwd)/global-excludes\"\n> >> +       global_excludes=\"global-excludes\"\n> >>  }\n> >>\n> >>  enable_global_excludes () {\n> >> ---\n> >\n> > Since I do not have time for the lengthy, undirected discussion upstream\n> > seems to want to start, let's make your change, but only conditional on\n> > MINGW?\n> \n> I was just testing this -- I've already wrapped the suggested fix\n> within a \"test_have_prereq MINGW\" for our fork and committed it. This\n> was  an issue partly because was alias pwd to \"pwd -W\" and so always\n> get Windows paths. It means the test here doesn't check absolute paths\n> but I think we can live with that. I tried using $(builtin pwd) to\n> avoid the \"-W\" but it didn't help and I still got C: style paths.\n> \n> I also grabbed Karsten's patch \"dir.c: fix ignore processing within\n> not-ignored directories\" as this appears to deal with a .gitignore\n> regression in 1.8.3. We can carry this until the next merge with\n> upstream.\n\nThanks!\nDscho\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"msysGit\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/groups/opt_out.\n"}]}