cgit: orientation
Adriaan de Groot
adridg at freebsd.org
Thu Feb 11 10:24:24 UTC 2021
On Wednesday, 10 February 2021 01:52:32 CET Warner Losh wrote:
> On Tue, Feb 9, 2021 at 5:47 PM Graham Perrin <grahamperrin at gmail.com> wrote:
> > Given this, for example:
> >
> > <
> > https://cgit.freebsd.org/src/commit/?id=174a7e578a33c01401e33f9bfcc077fc31
> > 55251c&h=stable%2F12
> >
> >
> > – with 'stable' in the URL and 'stable/12' visible in the page – how
> > would a reader know that the commit was to main (not stable/12)?
> >
> > Is there scope to make improved use of cgit, or is this a limitation of
> > cgit?
>
> There's a pulldown in the upper right corner that says 'stable/12' though
> it took me a while to find it as my eyes glided over it a couple of times.
cgit, though, is just not a very featureful history browser. It does the bare
minimum, but phabricator or gitlab give you a much nicer (although in their
own way slow and/or clunky) history view.
Call me old-school, but
- if you're asking this kind of question, you probably have a checkout already
- if you have a checkout, you probably have git(1) installed,. too
- just use the command-line:
git branch --contains 174a7e578a
git branch -r --contains 174a7e578a
The latter tells you what branches all have the named commit in their
ancestry. You could add a git alias:
git config --global alias.what-branch "branch -r --contains"
and then you can do
git what-branch 174a7e578a
Buut, yeah, cgit. If you happen to hit a commit at the tip of a branch,
there's some decoration but the combination of id and branch in the URL can be
complete nonsense, e.g.
https://cgit.freebsd.org/src/commit/?
id=a7c68340584c942792188ad50593d4ef15cc8982&h=releng%2F5.5
will give you Warner's latest ACPI commit for EPYC, from which you can
conclude it was in 5.5-RELEASE :|
[ade]
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 659 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.freebsd.org/pipermail/freebsd-current/attachments/20210211/74c49bea/attachment.sig>
More information about the freebsd-current
mailing list