git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* git-gui: How to configure for use in gigantic projects?
@ 2020-10-30 10:16 Birger Skogeng Pedersen
  2020-10-30 10:30 ` Konstantin Tokarev
                   ` (2 more replies)
  0 siblings, 3 replies; 5+ messages in thread
From: Birger Skogeng Pedersen @ 2020-10-30 10:16 UTC (permalink / raw)
  To: Git List

Hi,

I would like to use git gui for a project. The problem is that the
repository directory is really gigantic. Doing a scan (F5) takes a
couple of minutes to finish.

I would like the scan to only focus on files that are specifically
added to the index. In git I do this:

git config status.showUntrackedFiles no

git status will then only show status of files that I have
specifically added. So git status completion is instant.

But this configuration appears to have no effect on git-gui. The scan
is just as slow as before.

Anything I can do to make git-gui only scan files that are
specifically added, and not look through the whole directory?

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: git-gui: How to configure for use in gigantic projects?
  2020-10-30 10:16 git-gui: How to configure for use in gigantic projects? Birger Skogeng Pedersen
@ 2020-10-30 10:30 ` Konstantin Tokarev
  2020-10-30 10:58 ` Pratyush Yadav
  2020-10-30 14:06 ` Marc Branchaud
  2 siblings, 0 replies; 5+ messages in thread
From: Konstantin Tokarev @ 2020-10-30 10:30 UTC (permalink / raw)
  To: Birger Skogeng Pedersen, Git List



30.10.2020, 13:16, "Birger Skogeng Pedersen" <birger.sp@gmail.com>:
> Hi,
>
> I would like to use git gui for a project. The problem is that the
> repository directory is really gigantic. Doing a scan (F5) takes a
> couple of minutes to finish.
>
> I would like the scan to only focus on files that are specifically
> added to the index. In git I do this:
>
> git config status.showUntrackedFiles no
>
> git status will then only show status of files that I have
> specifically added. So git status completion is instant.
>
> But this configuration appears to have no effect on git-gui. The scan
> is just as slow as before.
>
> Anything I can do to make git-gui only scan files that are
> specifically added, and not look through the whole directory?

FWIW, there are better ways to improve performance of git status without
hiding untracked files (which are useful to see when new files are added):

* Add all uninteresting files and directories to .gitignore
* Use fast storage for git repository, e.g. NVME-based
* If your OS can handle filesystem cache efficiently (e.g., Linux) make sure 
there is enough of free RAM for caches and all repeated operations on
same files and directories will speed up dramatically
* If your OS cannot handle filesystem cache efficiently (e.g. Windows) consider
using different OS for development
* If overall performance is still not sufficient, consider using fsmonitor hook [1]

[1] https://github.blog/2018-04-05-git-217-released/#speeding-up-status-with-watchman



-- 
Regards,
Konstantin

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: git-gui: How to configure for use in gigantic projects?
  2020-10-30 10:16 git-gui: How to configure for use in gigantic projects? Birger Skogeng Pedersen
  2020-10-30 10:30 ` Konstantin Tokarev
@ 2020-10-30 10:58 ` Pratyush Yadav
  2020-10-30 11:11   ` Birger Skogeng Pedersen
  2020-10-30 14:06 ` Marc Branchaud
  2 siblings, 1 reply; 5+ messages in thread
From: Pratyush Yadav @ 2020-10-30 10:58 UTC (permalink / raw)
  To: Birger Skogeng Pedersen; +Cc: Git List

Hi Birger,

On 30/10/20 11:16AM, Birger Skogeng Pedersen wrote:
> Hi,
> 
> I would like to use git gui for a project. The problem is that the
> repository directory is really gigantic. Doing a scan (F5) takes a
> couple of minutes to finish.
> 
> I would like the scan to only focus on files that are specifically
> added to the index. In git I do this:
> 
> git config status.showUntrackedFiles no
> 
> git status will then only show status of files that I have
> specifically added. So git status completion is instant.
> 
> But this configuration appears to have no effect on git-gui. The scan
> is just as slow as before.
> 
> Anything I can do to make git-gui only scan files that are
> specifically added, and not look through the whole directory?

Uncheck "Show untracked files" in options. It is controlled by the 
config 'gui.displayuntracked'.

-- 
Regards,
Pratyush Yadav

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: git-gui: How to configure for use in gigantic projects?
  2020-10-30 10:58 ` Pratyush Yadav
@ 2020-10-30 11:11   ` Birger Skogeng Pedersen
  0 siblings, 0 replies; 5+ messages in thread
From: Birger Skogeng Pedersen @ 2020-10-30 11:11 UTC (permalink / raw)
  To: Pratyush Yadav; +Cc: Git List

Ah, that one changed everything! Thank you Pratyush!

On Fri, Oct 30, 2020 at 11:59 AM Pratyush Yadav <me@yadavpratyush.com> wrote:
>
> Hi Birger,
>
> On 30/10/20 11:16AM, Birger Skogeng Pedersen wrote:
> > Hi,
> >
> > I would like to use git gui for a project. The problem is that the
> > repository directory is really gigantic. Doing a scan (F5) takes a
> > couple of minutes to finish.
> >
> > I would like the scan to only focus on files that are specifically
> > added to the index. In git I do this:
> >
> > git config status.showUntrackedFiles no
> >
> > git status will then only show status of files that I have
> > specifically added. So git status completion is instant.
> >
> > But this configuration appears to have no effect on git-gui. The scan
> > is just as slow as before.
> >
> > Anything I can do to make git-gui only scan files that are
> > specifically added, and not look through the whole directory?
>
> Uncheck "Show untracked files" in options. It is controlled by the
> config 'gui.displayuntracked'.
>
> --
> Regards,
> Pratyush Yadav

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: git-gui: How to configure for use in gigantic projects?
  2020-10-30 10:16 git-gui: How to configure for use in gigantic projects? Birger Skogeng Pedersen
  2020-10-30 10:30 ` Konstantin Tokarev
  2020-10-30 10:58 ` Pratyush Yadav
@ 2020-10-30 14:06 ` Marc Branchaud
  2 siblings, 0 replies; 5+ messages in thread
From: Marc Branchaud @ 2020-10-30 14:06 UTC (permalink / raw)
  To: Birger Skogeng Pedersen, Git List

On 2020-10-30 6:16 a.m., Birger Skogeng Pedersen wrote:
> Hi,
> 
> I would like to use git gui for a project. The problem is that the
> repository directory is really gigantic. Doing a scan (F5) takes a
> couple of minutes to finish.

I've found that enabling Trust File Modification Time helps, at the cost 
of git-gui doing (very) occasional rescans when it notices that a file 
it thought was modified turns out to be unmodified.  As Konstantin said, 
things generally improve once the initial scan primes the disk cache.  YMMV.

The setting is in the Preferences, or "git config gui.trustmtime true".

		M.


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-10-30 14:07 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-10-30 10:16 git-gui: How to configure for use in gigantic projects? Birger Skogeng Pedersen
2020-10-30 10:30 ` Konstantin Tokarev
2020-10-30 10:58 ` Pratyush Yadav
2020-10-30 11:11   ` Birger Skogeng Pedersen
2020-10-30 14:06 ` Marc Branchaud

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).