{"thread":{"id":"21902","subject":"[BUG] Bad msysgit/egit interaction over dotfiles","startedAt":"2009-12-08T13:28:57Z","lastAt":"2009-12-14T11:45:09Z","messageCount":9,"participants":["Yann Dirson","Erik Faye-Lund","Ferry Huberts","Marius Storm-Olsen","Johannes Schindelin"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"129530","messageId":"20091208132857.GB5425@linagora.com","threadId":"21902","inReplyTo":null,"subject":"[BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Yann Dirson","fromEmail":"ydirson@linagora.com","sentAt":"2009-12-08T13:28:57Z","receivedAt":"2009-12-08T13:28:57Z","isPatch":false,"sender":{"key":"ydirson@linagora.com","avatar":null},"body":"Some devs here started to use egit on windows, and since egit is not\ncomplete yet, occasionally^Wregularly use msysgit for\nrebase/stash/you-name-it.\n\nThis revealed a strange problem that took some time figuring out,\nwhere eclipse refused to write to .classpath or .project, just saying\n\"could not write\", while other apps had no problem editing the same\nfiles.\n\nIn the end, the problem is that the dotfiles had the \"hidden\" bit set,\nand that for some reason eclipse does not allow to write to hidden\nfiles - and that the one (re)setting the \"hidden\" bit over and over\nagain is msysgit, whenever it checkouts such a dotfile - surely to\nemulate the unix behaviour of hiding dotfiles by default.\n\nI'm not sure who's at fault here - namely, I can't see any valid\nreason for eclipse to refuse such writes, but I am not sure it is a\ngood reason for msysgit would set the hidden bit either.  In either\ncase, even if only for the short term, I think msysgit should ensure\nthat this bit does not get set (possibly circumventing any magic msys\nwould do behind its back).\n\nBest regards,\n-- \nYann\n"},{"id":"129531","messageId":"40aa078e0912080534x32fe9724xcda47ad46dbdb7c0@mail.gmail.com","threadId":"21902","inReplyTo":"20091208132857.GB5425@linagora.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@googlemail.com","sentAt":"2009-12-08T13:34:59Z","receivedAt":"2009-12-08T13:34:59Z","isPatch":false,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"On Tue, Dec 8, 2009 at 2:28 PM, Yann Dirson <ydirson@linagora.com> wrote:\n> I'm not sure who's at fault here - namely, I can't see any valid\n> reason for eclipse to refuse such writes, but I am not sure it is a\n> good reason for msysgit would set the hidden bit either.  In either\n> case, even if only for the short term, I think msysgit should ensure\n> that this bit does not get set (possibly circumventing any magic msys\n> would do behind its back).\n\nSetting the config option \"core.hidedotfiles\" to \"false\" should\nprevent this from happening.\n\n-- \nErik \"kusma\" Faye-Lund\n"},{"id":"129537","messageId":"4B1E57BF.1000500@pelagic.nl","threadId":"21902","inReplyTo":"40aa078e0912080534x32fe9724xcda47ad46dbdb7c0@mail.gmail.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Ferry Huberts","fromEmail":"ferry.huberts@pelagic.nl","sentAt":"2009-12-08T13:42:23Z","receivedAt":"2009-12-08T13:42:23Z","isPatch":false,"sender":{"key":"ferry.huberts@pelagic.nl","avatar":"https://gravatar.com/avatar/9f63c0289ad23cbdef0f7609a0af85ff0f4b3babfd066de9ff58f62d48cfd6f2?d=mp&s=160"},"body":"On 12/08/2009 02:34 PM, Erik Faye-Lund wrote:\n> On Tue, Dec 8, 2009 at 2:28 PM, Yann Dirson <ydirson@linagora.com> wrote:\n>> I'm not sure who's at fault here - namely, I can't see any valid\n>> reason for eclipse to refuse such writes, but I am not sure it is a\n>> good reason for msysgit would set the hidden bit either.  In either\n>> case, even if only for the short term, I think msysgit should ensure\n>> that this bit does not get set (possibly circumventing any magic msys\n>> would do behind its back).\n> \n> Setting the config option \"core.hidedotfiles\" to \"false\" should\n> prevent this from happening.\n> \n\nwhy isn't this the default?\n\nI also experienced this change in behaviour and I thought we would\nstrive to keep the experience the same.\n"},{"id":"129540","messageId":"40aa078e0912080623q108b2affk80534ccd5fd7ace3@mail.gmail.com","threadId":"21902","inReplyTo":"4B1E57BF.1000500@pelagic.nl","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@googlemail.com","sentAt":"2009-12-08T14:23:55Z","receivedAt":"2009-12-08T14:23:55Z","isPatch":false,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"On Tue, Dec 8, 2009 at 2:42 PM, Ferry Huberts <ferry.huberts@pelagic.nl> wrote:\n> On 12/08/2009 02:34 PM, Erik Faye-Lund wrote:\n>> On Tue, Dec 8, 2009 at 2:28 PM, Yann Dirson <ydirson@linagora.com> wrote:\n>>> I'm not sure who's at fault here - namely, I can't see any valid\n>>> reason for eclipse to refuse such writes, but I am not sure it is a\n>>> good reason for msysgit would set the hidden bit either.  In either\n>>> case, even if only for the short term, I think msysgit should ensure\n>>> that this bit does not get set (possibly circumventing any magic msys\n>>> would do behind its back).\n>>\n>> Setting the config option \"core.hidedotfiles\" to \"false\" should\n>> prevent this from happening.\n>>\n>\n> why isn't this the default?\n>\n> I also experienced this change in behaviour and I thought we would\n> strive to keep the experience the same.\n>\n\nYou can follow the discussion here:\nhttp://code.google.com/p/msysgit/issues/detail?id=288\n\nI believe the reason is something like \"because someone suggested it,\nand no one disagreed\". Do you have a good argument why it shouldn't be\nthe default (other than \"it's a change\", because changing it back now\nwould also be a change)?\n\n-- \nErik \"kusma\" Faye-Lund\n"},{"id":"129544","messageId":"20091208143700.GC5425@linagora.com","threadId":"21902","inReplyTo":"40aa078e0912080623q108b2affk80534ccd5fd7ace3@mail.gmail.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Yann Dirson","fromEmail":"ydirson@linagora.com","sentAt":"2009-12-08T14:37:00Z","receivedAt":"2009-12-08T14:37:00Z","isPatch":false,"sender":{"key":"ydirson@linagora.com","avatar":null},"body":"On Tue, Dec 08, 2009 at 03:23:55PM +0100, Erik Faye-Lund wrote:\n> On Tue, Dec 8, 2009 at 2:42 PM, Ferry Huberts <ferry.huberts@pelagic.nl> wrote:\n> > On 12/08/2009 02:34 PM, Erik Faye-Lund wrote:\n> >> On Tue, Dec 8, 2009 at 2:28 PM, Yann Dirson <ydirson@linagora.com> wrote:\n> >>> I'm not sure who's at fault here - namely, I can't see any valid\n> >>> reason for eclipse to refuse such writes, but I am not sure it is a\n> >>> good reason for msysgit would set the hidden bit either.  In either\n> >>> case, even if only for the short term, I think msysgit should ensure\n> >>> that this bit does not get set (possibly circumventing any magic msys\n> >>> would do behind its back).\n> >>\n> >> Setting the config option \"core.hidedotfiles\" to \"false\" should\n> >> prevent this from happening.\n\nRight, it works much better this way.\n\n\n> > why isn't this the default?\n> >\n> > I also experienced this change in behaviour and I thought we would\n> > strive to keep the experience the same.\n> >\n> \n> You can follow the discussion here:\n> http://code.google.com/p/msysgit/issues/detail?id=288\n> \n> I believe the reason is something like \"because someone suggested it,\n> and no one disagreed\". Do you have a good argument why it shouldn't be\n> the default (other than \"it's a change\", because changing it back now\n> would also be a change)?\n\nDepending on the opinion of the Eclipse guys on this issue about\n\"writing to hidden files only says 'could not write'\", which arguably\ncould be seen as a bug on their side, we can see changing this\nbehaviour back to the default on the msysgit side as either a\n(possibly temporary) workaround for a known eclipse bug, or as getting\nagain interoperable with egit.\n\nNote that I did not get time yet to fully investigate the eclipse\nstatus on the issue.\n\nBest regards,\n-- \nYann\n"},{"id":"129661","messageId":"4B200EF5.2060606@gmail.com","threadId":"21902","inReplyTo":"20091208143700.GC5425@linagora.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Marius Storm-Olsen","fromEmail":"mstormo@gmail.com","sentAt":"2009-12-09T20:56:21Z","receivedAt":"2009-12-09T20:56:21Z","isPatch":false,"sender":{"key":"mstormo@gmail.com","avatar":"https://avatars.githubusercontent.com/u/1500?v=4"},"body":"Yann Dirson said the following on 08.12.2009 15:37:\n> On Tue, Dec 08, 2009 at 03:23:55PM +0100, Erik Faye-Lund wrote:\n>> You can follow the discussion here:\n>> http://code.google.com/p/msysgit/issues/detail?id=288\n>>\n>> I believe the reason is something like \"because someone suggested\n>> it, and no one disagreed\". Do you have a good argument why it\n>> shouldn't be the default (other than \"it's a change\", because\n>> changing it back now would also be a change)?\n>\n> Depending on the opinion of the Eclipse guys on this issue about\n> \"writing to hidden files only says 'could not write'\", which\n> arguably could be seen as a bug on their side, we can see changing\n> this behaviour back to the default on the msysgit side as either a\n> (possibly temporary) workaround for a known eclipse bug, or as\n> getting again interoperable with egit.\n\nDot-files on unix are considered hidden. It's the only way files are \nhidden there. Not so on Windows. Dot-files are just like any normal \nfile, and you need to mark a file hidden.\n\nSo, the logic of egit, that *actually* hidden files should not be \nwritten to, but dot-files should, seems to me to be a bug in egit. \nThere should be no reason why egit shouldn't be able to write to any \nfile, pending permissions. I'd say file a bug report with egit.\n\n--\n.marius\n"},{"id":"129834","messageId":"20091210083514.GA5971@linagora.com","threadId":"21902","inReplyTo":"4B200EF5.2060606@gmail.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Yann Dirson","fromEmail":"ydirson@linagora.com","sentAt":"2009-12-10T08:35:14Z","receivedAt":"2009-12-10T08:35:14Z","isPatch":false,"sender":{"key":"ydirson@linagora.com","avatar":null},"body":"On Wed, Dec 09, 2009 at 09:56:21PM +0100, Marius Storm-Olsen wrote:\n> Yann Dirson said the following on 08.12.2009 15:37:\n> >On Tue, Dec 08, 2009 at 03:23:55PM +0100, Erik Faye-Lund wrote:\n> >>You can follow the discussion here:\n> >>http://code.google.com/p/msysgit/issues/detail?id=288\n> >>\n> >>I believe the reason is something like \"because someone suggested\n> >>it, and no one disagreed\". Do you have a good argument why it\n> >>shouldn't be the default (other than \"it's a change\", because\n> >>changing it back now would also be a change)?\n> >\n> >Depending on the opinion of the Eclipse guys on this issue about\n> >\"writing to hidden files only says 'could not write'\", which\n> >arguably could be seen as a bug on their side, we can see changing\n> >this behaviour back to the default on the msysgit side as either a\n> >(possibly temporary) workaround for a known eclipse bug, or as\n> >getting again interoperable with egit.\n> \n> Dot-files on unix are considered hidden. It's the only way files are\n> hidden there. Not so on Windows. Dot-files are just like any normal\n> file, and you need to mark a file hidden.\n> \n> So, the logic of egit, that *actually* hidden files should not be\n> written to, but dot-files should, seems to me to be a bug in egit.\n> There should be no reason why egit shouldn't be able to write to any\n> file, pending permissions. I'd say file a bug report with egit.\n\nActually it is not egit who is unable to write to the file, but\neclipse itself, and I do tend to think it is a bug in eclipse.  But\nnow, even if we can convince the eclipse guys that it is a bug, it\nwill be some time before a new release with this bug fixed gets\npublished.\n\nSo IMHO it would makes sense, for the sake of usability, to not\nactivate the \"hide dotfiles\" feature by default.  It is easier for\nsomeone seeing unwanted dotfiles to find the switch to hide them, than\nfor someone getting a \"could not write\" message from eclipse to\nunderstand that there is a seemingly-unrelate switch for msysgit to\navoid this situation.\n\nBut maybe the situation is not so clear.  That \"hide dotfiles\" was\nimplemented so that \".git\" at first, and then \".git*\" files do not\nclutter the view of the project.  But then, if a git repo has other\ndotfiles, those are really *part of* the versionned stuff, so I do not\nsee why those should be hidden at all.  After all, the .project,\n.classpath, and other eclipse project files have that name on windows\ntoo, and it will indeed *confuse* people to get them hidden.\n\nSo should we have 2 classes of dotfiles, those \"private to git\", and\nthe others, one class being hidden while the others are not ?  I am\nnot sure at all this would be a good idea either.  Or maybe we should\nonly get .git hidden - after all, that one is the only real metadata\nnot part of the versionned stuff itself ?\n\nMaybe we should add some sort of \"core.hidedotfiles = dotgitonly\"\nsetting, and make that the default ?  That one does not appear to\ncause any problems to jgit, and eclipse itself has not business with\nit, so it would IMHO make sense.\n\nOpinions ?\n"},{"id":"129835","messageId":"40aa078e0912140113w23823058h4ca691963761d3be@mail.gmail.com","threadId":"21902","inReplyTo":"20091210083514.GA5971@linagora.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Erik Faye-Lund","fromEmail":"kusmabite@googlemail.com","sentAt":"2009-12-14T09:13:37Z","receivedAt":"2009-12-14T09:13:37Z","isPatch":false,"sender":{"key":"kusmabite@gmail.com","avatar":"https://avatars.githubusercontent.com/u/47073?v=4"},"body":"On Thu, Dec 10, 2009 at 9:35 AM, Yann Dirson <ydirson@linagora.com> wrote:\n> On Wed, Dec 09, 2009 at 09:56:21PM +0100, Marius Storm-Olsen wrote:\n>> Yann Dirson said the following on 08.12.2009 15:37:\n>> >On Tue, Dec 08, 2009 at 03:23:55PM +0100, Erik Faye-Lund wrote:\n>> >>You can follow the discussion here:\n>> >>http://code.google.com/p/msysgit/issues/detail?id=288\n>> >>\n>> >>I believe the reason is something like \"because someone suggested\n>> >>it, and no one disagreed\". Do you have a good argument why it\n>> >>shouldn't be the default (other than \"it's a change\", because\n>> >>changing it back now would also be a change)?\n>> >\n>> >Depending on the opinion of the Eclipse guys on this issue about\n>> >\"writing to hidden files only says 'could not write'\", which\n>> >arguably could be seen as a bug on their side, we can see changing\n>> >this behaviour back to the default on the msysgit side as either a\n>> >(possibly temporary) workaround for a known eclipse bug, or as\n>> >getting again interoperable with egit.\n>>\n>> Dot-files on unix are considered hidden. It's the only way files are\n>> hidden there. Not so on Windows. Dot-files are just like any normal\n>> file, and you need to mark a file hidden.\n>>\n>> So, the logic of egit, that *actually* hidden files should not be\n>> written to, but dot-files should, seems to me to be a bug in egit.\n>> There should be no reason why egit shouldn't be able to write to any\n>> file, pending permissions. I'd say file a bug report with egit.\n>\n> Actually it is not egit who is unable to write to the file, but\n> eclipse itself, and I do tend to think it is a bug in eclipse.  But\n> now, even if we can convince the eclipse guys that it is a bug, it\n> will be some time before a new release with this bug fixed gets\n> published.\n>\n> So IMHO it would makes sense, for the sake of usability, to not\n> activate the \"hide dotfiles\" feature by default.  It is easier for\n> someone seeing unwanted dotfiles to find the switch to hide them, than\n> for someone getting a \"could not write\" message from eclipse to\n> understand that there is a seemingly-unrelate switch for msysgit to\n> avoid this situation.\n>\n\nActually, I think it makes much more sense to put a note of the issue\nin the release-notes. I don't want people to lose features because\nEclipse, an IDE I don't even use, is broken. Since Eclipse is the\nculprit here, I think it's the Eclipse that should \"take the hit\", not\nthe rest of us.\n\nThis of course assumes that hidden dotfiles is a feature that people\nwant, which is what I assumed was the reason why it was added in the\nfirst place. Personally I don't care about this feature, since I have\nthe \"show hidden files\"-feature turned on.\n\n> But maybe the situation is not so clear.  That \"hide dotfiles\" was\n> implemented so that \".git\" at first, and then \".git*\" files do not\n> clutter the view of the project.  But then, if a git repo has other\n> dotfiles, those are really *part of* the versionned stuff, so I do not\n> see why those should be hidden at all.  After all, the .project,\n> .classpath, and other eclipse project files have that name on windows\n> too, and it will indeed *confuse* people to get them hidden.\n>\n> So should we have 2 classes of dotfiles, those \"private to git\", and\n> the others, one class being hidden while the others are not ?  I am\n> not sure at all this would be a good idea either.  Or maybe we should\n> only get .git hidden - after all, that one is the only real metadata\n> not part of the versionned stuff itself ?\n>\n> Maybe we should add some sort of \"core.hidedotfiles = dotgitonly\"\n> setting, and make that the default ?  That one does not appear to\n> cause any problems to jgit, and eclipse itself has not business with\n> it, so it would IMHO make sense.\n>\n> Opinions ?\n>\n\nIF we were to go down this path, perhaps it would be even better to\nuse some sort of file-pattern or even squeeze this into gitattributes?\nI guess something like \".* +hidden\" should emulate the unix behaviour\n(given that we add a hidden attribute). I don't think we have a global\ngitattributes file though, so it'd have to be added to each repo where\nthe effect is desired, I guess.\n\n-- \nErik \"kusma\" Faye-Lund\n"},{"id":"129864","messageId":"alpine.DEB.1.00.0912141241000.4985@pacific.mpi-cbg.de","threadId":"21902","inReplyTo":"40aa078e0912140113w23823058h4ca691963761d3be@mail.gmail.com","subject":"Re: [BUG] Bad msysgit/egit interaction over dotfiles","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2009-12-14T11:45:09Z","receivedAt":"2009-12-14T11:45:09Z","isPatch":false,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"Hi,\n\nOn Mon, 14 Dec 2009, Erik Faye-Lund wrote:\n\n> On Thu, Dec 10, 2009 at 9:35 AM, Yann Dirson <ydirson@linagora.com> wrote:\n>\n> > [discussion revolving around \".*\" being marked hidden on Windows]\n> >\n> > But maybe the situation is not so clear.  That \"hide dotfiles\" was \n> > implemented so that \".git\" at first, and then \".git*\" files do not \n> > clutter the view of the project.  But then, if a git repo has other \n> > dotfiles, those are really *part of* the versionned stuff, so I do not \n> > see why those should be hidden at all.  After all, the .project, \n> > .classpath, and other eclipse project files have that name on windows \n> > too, and it will indeed *confuse* people to get them hidden.\n> >\n> > So should we have 2 classes of dotfiles, those \"private to git\", and\n> > the others, one class being hidden while the others are not ?  I am\n> > not sure at all this would be a good idea either.  Or maybe we should\n> > only get .git hidden - after all, that one is the only real metadata\n> > not part of the versionned stuff itself ?\n> >\n> > Maybe we should add some sort of \"core.hidedotfiles = dotgitonly\"\n> > setting, and make that the default ?  That one does not appear to\n> > cause any problems to jgit, and eclipse itself has not business with\n> > it, so it would IMHO make sense.\n> >\n> > Opinions ?\n> >\n> \n> IF we were to go down this path, perhaps it would be even better to\n> use some sort of file-pattern or even squeeze this into gitattributes?\n> I guess something like \".* +hidden\" should emulate the unix behaviour\n> (given that we add a hidden attribute). I don't think we have a global\n> gitattributes file though, so it'd have to be added to each repo where\n> the effect is desired, I guess.\n\nActually, I think the original request was really for all the dot files, \nnot just for .git.\n\nBut I can see the reasoning behind hiding only .git, which I would not \nlike to make the default, though.  I would like to make Eclipse users set \nthis explicitely in their /etc/gitconfig (possibly via the Git for Windows \ninstaller, just like the infamous -- and still broken -- core.autocrlf \nsetting, if Sebastian is nice enough to make yet another page in the \ninstaller).\n\nSo: I would definitely take a patch implementing \"core.hidedotfiles = \ndotgitonly\", but would hesitate to make it the default.\n\nCiao,\nDscho\n"}]}