git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [RFC PATCH 1/6] DO NOT MERGE: compute commit-graph on every commit

From
Stefan Beller <sbeller@google.com>
Date
May 31, 2018, 19:39 UTC
Message-ID
<CAGZ79kZ=Zmd8i9Z565MU=QCQGXixwkRYPY5RKekua67Lq+b2=g@mail.gmail.com>
In-Reply-To
<20180531174024.124488-2-dstolee@microsoft.com>
On Thu, May 31, 2018 at 10:41 AM, Derrick Stolee <dstolee@microsoft.com> wrote:
Show 30 quoted lines
> Also enable core.commitGraph and gc.commitGraph. Helps to test the
> commit-graph feature with the rest of the test infrastructure.
>
> Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
> ---
>  builtin/commit.c | 5 +++++
>  builtin/gc.c     | 2 +-
>  environment.c    | 2 +-
>  3 files changed, 7 insertions(+), 2 deletions(-)
>
> diff --git a/builtin/commit.c b/builtin/commit.c
> index e8e8d13be4..8751b816c1 100644
> --- a/builtin/commit.c
> +++ b/builtin/commit.c
> @@ -32,6 +32,7 @@
>  #include "column.h"
>  #include "sequencer.h"
>  #include "mailmap.h"
> +#include "commit-graph.h"
>
>  static const char * const builtin_commit_usage[] = {
>         N_("git commit [<options>] [--] <pathspec>..."),
> @@ -1623,5 +1624,9 @@ int cmd_commit(int argc, const char **argv, const char *prefix)
>
>         UNLEAK(err);
>         UNLEAK(sb);
> +
> +       if (core_commit_graph)
> +               write_commit_graph_reachable(get_object_directory(), 1);
> +

I'd personally put it before the UNLEAKS, as then we have the cleanup at the end of the function and not scattered somewhere in the middle.

Previous: Derrick StoleeNext: Derrick Stolee
Message 9 of 18 in “Fix commit-graph/graft/replace/shallow combo”
  1. 0/6 Fix commit-graph/graft/replace/shallow comboDerrick Stolee, May 31, 2018
  2. 4/6 commit-graph: avoid writing when repo is shallowDerrick Stolee, May 31, 2018
  3. Stefan BellerMay 31, 2018
  4. Junio C HamanoJun 1, 2018
  5. Derrick StoleeJun 1, 2018
  6. Jakub NarebskiJun 2, 2018
  7. Junio C HamanoJun 4, 2018
  8. 1/6 DO NOT MERGE: compute commit-graph on every commitDerrick Stolee, May 31, 2018
  9. Stefan BellerMay 31, 2018
  10. 5/6 fetch: destroy commit graph on shallow parametersDerrick Stolee, May 31, 2018
  11. Stefan BellerMay 31, 2018
  12. 2/6 DO NOT MERGE: write commit-graph on every fetchDerrick Stolee, May 31, 2018
  13. 3/6 commit-graph: enable replace-object and graftsDerrick Stolee, May 31, 2018
  14. Jakub NarebskiJun 9, 2018
  15. 6/6 commit-graph: revert to odb on missing parentsDerrick Stolee, May 31, 2018
  16. Stefan BellerMay 31, 2018
  17. Derrick StoleeJun 1, 2018
  18. Jakub NarebskiJun 8, 2018

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.