git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: "SZEDER Gábor" <szeder.dev@gmail.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: Jakub Narebski <jnareb@gmail.com>,
	Derrick Stolee <stolee@gmail.com>, Karl Ostmo <kostmo@gmail.com>,
	git@vger.kernel.org
Subject: Re: standalone library/tool to query commit-graph?
Date: Fri, 24 May 2019 00:20:31 +0200	[thread overview]
Message-ID: <20190523222031.GC951@szeder.dev> (raw)
In-Reply-To: <87tvdkg7ld.fsf@evledraar.gmail.com>

On Thu, May 23, 2019 at 11:54:22PM +0200, Ævar Arnfjörð Bjarmason wrote:
> 
> On Thu, May 23 2019, Jakub Narebski wrote:
> 
> > Derrick Stolee <stolee@gmail.com> writes:
> >> On 5/22/2019 2:49 PM, Karl Ostmo wrote:
> >
> >>> After producing the file ".git/objects/info/commit-graph" with the
> >>> command "git commit-graph write", is there a way to answer queries
> >>> like "git merge-base --is-ancestor" without having a .git directory?
> >>> E.g. is there a library that will operate on the "commit-graph" file
> >>> all by itself?
> >>
> >> You could certainly build such a tool, assuming your merge-base parameters are
> >> full-length commit ids. If you try to start at ref names, you'll need the .git
> >> directory.
> >>
> >> I would not expect such a tool to ever exist in the Git codebase. Instead, you
> >> would need a new project, say "graph-analyzer --graph=<path> --is-ancestor <id1> <id2>"
> >
> > It would be nice if such tool could convert commit-graph into other
> > commonly used augmented graph storage formats, like GEXF (Graph Exchange
> > XML Format), GraphML, GML (Graph Modelling Language), Pajek format or
> > Graphviz .dot format.
> 
> Wouldn't that make more sense as a hypothetical output format for "log
> --graph" rather than something you'd want to emit from the commit-graph?
> Presumably you'd want to export in such a format to see the shape of the
> repo, and since the commit graph doesn't include any commits outside of
> packs you'd miss any loose commits.

No, the commit-graph includes loose commits as well.


  reply	other threads:[~2019-05-23 22:20 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-22 18:49 standalone library/tool to query commit-graph? Karl Ostmo
2019-05-22 18:59 ` Derrick Stolee
2019-05-23 19:29   ` Jakub Narebski
2019-05-23 21:54     ` Ævar Arnfjörð Bjarmason
2019-05-23 22:20       ` SZEDER Gábor [this message]
2019-05-23 23:48         ` Derrick Stolee
2019-05-24  9:34           ` SZEDER Gábor
2019-05-24  9:49             ` Ævar Arnfjörð Bjarmason
2019-05-24 10:06               ` SZEDER Gábor
2019-05-24 10:49                 ` Ævar Arnfjörð Bjarmason
2019-05-24 11:37                   ` SZEDER Gábor
2019-06-25 18:27               ` Jakub Narebski

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

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20190523222031.GC951@szeder.dev \
    --to=szeder.dev@gmail.com \
    --cc=avarab@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=jnareb@gmail.com \
    --cc=kostmo@gmail.com \
    --cc=stolee@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 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).