{"thread":{"id":"54534","subject":"git-gui: How to configure for use in gigantic projects?","startedAt":"2020-10-30T10:16:37Z","lastAt":"2020-10-30T14:07:05Z","messageCount":5,"participants":["Birger Skogeng Pedersen","Konstantin Tokarev","Pratyush Yadav","Marc Branchaud"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"408724","messageId":"CAGr--=KpNaPFjMOzXzF382cv1p58nMoOPXAm0MCdA8WZMBznVA@mail.gmail.com","threadId":"54534","inReplyTo":null,"subject":"git-gui: How to configure for use in gigantic projects?","fromName":"Birger Skogeng Pedersen","fromEmail":"birger.sp@gmail.com","sentAt":"2020-10-30T10:16:21Z","receivedAt":"2020-10-30T10:16:37Z","isPatch":false,"sender":{"key":"birger.sp@gmail.com","avatar":"https://avatars.githubusercontent.com/u/5260237?v=4"},"body":"Hi,\n\nI would like to use git gui for a project. The problem is that the\nrepository directory is really gigantic. Doing a scan (F5) takes a\ncouple of minutes to finish.\n\nI would like the scan to only focus on files that are specifically\nadded to the index. In git I do this:\n\ngit config status.showUntrackedFiles no\n\ngit status will then only show status of files that I have\nspecifically added. So git status completion is instant.\n\nBut this configuration appears to have no effect on git-gui. The scan\nis just as slow as before.\n\nAnything I can do to make git-gui only scan files that are\nspecifically added, and not look through the whole directory?\n"},{"id":"408726","messageId":"445251604053314@mail.yandex.ru","threadId":"54534","inReplyTo":"CAGr--=KpNaPFjMOzXzF382cv1p58nMoOPXAm0MCdA8WZMBznVA@mail.gmail.com","subject":"Re: git-gui: How to configure for use in gigantic projects?","fromName":"Konstantin Tokarev","fromEmail":"annulen@yandex.ru","sentAt":"2020-10-30T10:30:28Z","receivedAt":"2020-10-30T10:36:58Z","isPatch":false,"sender":{"key":"annulen@yandex.ru","avatar":null},"body":"\n\n30.10.2020, 13:16, \"Birger Skogeng Pedersen\" <birger.sp@gmail.com>:\n> Hi,\n>\n> I would like to use git gui for a project. The problem is that the\n> repository directory is really gigantic. Doing a scan (F5) takes a\n> couple of minutes to finish.\n>\n> I would like the scan to only focus on files that are specifically\n> added to the index. In git I do this:\n>\n> git config status.showUntrackedFiles no\n>\n> git status will then only show status of files that I have\n> specifically added. So git status completion is instant.\n>\n> But this configuration appears to have no effect on git-gui. The scan\n> is just as slow as before.\n>\n> Anything I can do to make git-gui only scan files that are\n> specifically added, and not look through the whole directory?\n\nFWIW, there are better ways to improve performance of git status without\nhiding untracked files (which are useful to see when new files are added):\n\n* Add all uninteresting files and directories to .gitignore\n* Use fast storage for git repository, e.g. NVME-based\n* If your OS can handle filesystem cache efficiently (e.g., Linux) make sure \nthere is enough of free RAM for caches and all repeated operations on\nsame files and directories will speed up dramatically\n* If your OS cannot handle filesystem cache efficiently (e.g. Windows) consider\nusing different OS for development\n* If overall performance is still not sufficient, consider using fsmonitor hook [1]\n\n[1] https://github.blog/2018-04-05-git-217-released/#speeding-up-status-with-watchman\n\n\n\n-- \nRegards,\nKonstantin\n"},{"id":"408728","messageId":"20201030105856.ctjkxxwmudaeewpa@yadavpratyush.com","threadId":"54534","inReplyTo":"CAGr--=KpNaPFjMOzXzF382cv1p58nMoOPXAm0MCdA8WZMBznVA@mail.gmail.com","subject":"Re: git-gui: How to configure for use in gigantic projects?","fromName":"Pratyush Yadav","fromEmail":"me@yadavpratyush.com","sentAt":"2020-10-30T10:58:56Z","receivedAt":"2020-10-30T11:09:50Z","isPatch":false,"sender":{"key":"me@yadavpratyush.com","avatar":"https://avatars.githubusercontent.com/u/8817931?v=4"},"body":"Hi Birger,\n\nOn 30/10/20 11:16AM, Birger Skogeng Pedersen wrote:\n> Hi,\n> \n> I would like to use git gui for a project. The problem is that the\n> repository directory is really gigantic. Doing a scan (F5) takes a\n> couple of minutes to finish.\n> \n> I would like the scan to only focus on files that are specifically\n> added to the index. In git I do this:\n> \n> git config status.showUntrackedFiles no\n> \n> git status will then only show status of files that I have\n> specifically added. So git status completion is instant.\n> \n> But this configuration appears to have no effect on git-gui. The scan\n> is just as slow as before.\n> \n> Anything I can do to make git-gui only scan files that are\n> specifically added, and not look through the whole directory?\n\nUncheck \"Show untracked files\" in options. It is controlled by the \nconfig 'gui.displayuntracked'.\n\n-- \nRegards,\nPratyush Yadav\n"},{"id":"408729","messageId":"CAGr--=KTbc7zBaYavFPafXjEGT5PJC6UXw7cmW-fSgXpQagKFw@mail.gmail.com","threadId":"54534","inReplyTo":"20201030105856.ctjkxxwmudaeewpa@yadavpratyush.com","subject":"Re: git-gui: How to configure for use in gigantic projects?","fromName":"Birger Skogeng Pedersen","fromEmail":"birger.sp@gmail.com","sentAt":"2020-10-30T11:11:21Z","receivedAt":"2020-10-30T11:21:08Z","isPatch":false,"sender":{"key":"birger.sp@gmail.com","avatar":"https://avatars.githubusercontent.com/u/5260237?v=4"},"body":"Ah, that one changed everything! Thank you Pratyush!\n\nOn Fri, Oct 30, 2020 at 11:59 AM Pratyush Yadav <me@yadavpratyush.com> wrote:\n>\n> Hi Birger,\n>\n> On 30/10/20 11:16AM, Birger Skogeng Pedersen wrote:\n> > Hi,\n> >\n> > I would like to use git gui for a project. The problem is that the\n> > repository directory is really gigantic. Doing a scan (F5) takes a\n> > couple of minutes to finish.\n> >\n> > I would like the scan to only focus on files that are specifically\n> > added to the index. In git I do this:\n> >\n> > git config status.showUntrackedFiles no\n> >\n> > git status will then only show status of files that I have\n> > specifically added. So git status completion is instant.\n> >\n> > But this configuration appears to have no effect on git-gui. The scan\n> > is just as slow as before.\n> >\n> > Anything I can do to make git-gui only scan files that are\n> > specifically added, and not look through the whole directory?\n>\n> Uncheck \"Show untracked files\" in options. It is controlled by the\n> config 'gui.displayuntracked'.\n>\n> --\n> Regards,\n> Pratyush Yadav\n"},{"id":"408742","messageId":"dc3de1d7-43b2-20da-5e68-2652b35ce784@xiplink.com","threadId":"54534","inReplyTo":"CAGr--=KpNaPFjMOzXzF382cv1p58nMoOPXAm0MCdA8WZMBznVA@mail.gmail.com","subject":"Re: git-gui: How to configure for use in gigantic projects?","fromName":"Marc Branchaud","fromEmail":"marcnarc@xiplink.com","sentAt":"2020-10-30T14:06:01Z","receivedAt":"2020-10-30T14:07:05Z","isPatch":false,"sender":{"key":"marcnarc@xiplink.com","avatar":"https://avatars.githubusercontent.com/u/14980203?v=4"},"body":"On 2020-10-30 6:16 a.m., Birger Skogeng Pedersen wrote:\n> Hi,\n> \n> I would like to use git gui for a project. The problem is that the\n> repository directory is really gigantic. Doing a scan (F5) takes a\n> couple of minutes to finish.\n\nI've found that enabling Trust File Modification Time helps, at the cost \nof git-gui doing (very) occasional rescans when it notices that a file \nit thought was modified turns out to be unmodified.  As Konstantin said, \nthings generally improve once the initial scan primes the disk cache.  YMMV.\n\nThe setting is in the Preferences, or \"git config gui.trustmtime true\".\n\n\t\tM.\n\n"}]}