From: Yuri Khan <yuri.v.khan@gmail.com>
To: "Gerd Möllmann" <gerd.moellmann@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Tip: git commit-graph
Date: Thu, 12 Oct 2023 00:53:55 +0700 [thread overview]
Message-ID: <CAP_d_8VsH=gLKL+UVCJ8_Swch7sxz7y3sf7LgCWNCz92k9LRVQ@mail.gmail.com> (raw)
In-Reply-To: <m2ttqxm5q0.fsf@Pro.fritz.box>
On Thu, 12 Oct 2023 at 00:25, Gerd Möllmann <gerd.moellmann@gmail.com> wrote:
> >> A tip for people with slow machines,
> >>
> >> https://devblogs.microsoft.com/devops/updates-to-the-git-commit-graph-feature/
> >>
> >> This speeds up topological sorting of git commits, which is, for
> >> instance, used in git log --graph, which in turn is default in Magit.
> >
> > This seems to have been turned on by default 4 years ago and present
> > in two latest Ubuntu LTS releases (20.04 and 22.04) and two latest
> > Debian stables (bullseye and bookworm), so… which categories of Git
> > users would not already have it by now?
>
> I'm not sure what you mean by activated.
>
> Do you mean that on these systems, .git/objects/info/callgraphs is
> always generated? I'm no macOS 14.0, BTW, and I'm pretty sure that it
> wasn't generated, because of the speed difference I observe.
Hm. The article says
> In the recently released Git version 2.24.0, the commit-graph is enabled by default!
but what it actually seems to mean is that 2.24 changes the defaults
for two configuration variables to ‘true’:
* ‘core.commitGraph’ which instructs Git to *use* the file if present; and
* ‘gc.writeCommitGraph’ which instructs it to *create or update* the
file on every invocation of ‘git gc’.
So this answers my question: Users who have not run ‘git gc’ since
2019, or ‘git commit-graph write’ ever, will not already have a
serialized commit graph.
next prev parent reply other threads:[~2023-10-11 17:53 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-10-11 10:51 Tip: git commit-graph Gerd Möllmann
2023-10-11 16:17 ` Fu Yuan
2023-10-11 17:12 ` Yuri Khan
2023-10-11 17:25 ` Gerd Möllmann
2023-10-11 17:53 ` Yuri Khan [this message]
2023-10-11 18:30 ` Gerd Möllmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAP_d_8VsH=gLKL+UVCJ8_Swch7sxz7y3sf7LgCWNCz92k9LRVQ@mail.gmail.com' \
--to=yuri.v.khan@gmail.com \
--cc=emacs-devel@gnu.org \
--cc=gerd.moellmann@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.