Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 23 Mar 2021 02:25:00 -0400
From:      Janos Dohanics <web@3dresearch.com>
To:        FreeBSD Questions <freebsd-questions@freebsd.org>
Subject:   Re: /usr/src revision number
Message-ID:  <20210323022500.275ed6e09b1ef0bc59f47af3@3dresearch.com>
In-Reply-To: <CAN6yY1vQg1qchoGuECb8smBzQxk9A12=MS0%2BRCMMg-vOnJeLHA@mail.gmail.com>
References:  <20210321165225.11fa1f5559373032ea629412@3dresearch.com> <CAN6yY1vQg1qchoGuECb8smBzQxk9A12=MS0%2BRCMMg-vOnJeLHA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 21 Mar 2021 15:35:54 -0700
Kevin Oberman <rkoberman@gmail.com> wrote:

> On Sun, Mar 21, 2021 at 1:53 PM Janos Dohanics <web@3dresearch.com>
> wrote:
> [...]
> >
> > How can I find what "revision" do I have now in /usr/src and how
> > can I see if it is an increment compared to the installed
> > kernel/userland?
> >
> > --
> > Janos Dohanics
> >
> 
> 
> > Take a look at the newd git "Getting started" guide at
> > https://docs.freebsd.org/en/articles/committers-guide/#git-primer.
> > If you use a shallow clone, there is no easy way. If you have a
> > full clone, you will have a hash starting with 'n' followed by 6
> > digits. This is a sequence count of commits to the relevant branch.
> > In your case, the sequence is n244684.

Thank you, started the local repo anew with 'deep' cloning and rebuilt
world+kernel.

I now have:

# uname -v
FreeBSD 13.0-STABLE #0 stable/13-n245008-3aa6cc000f7: Mon Mar 22 14:42:44 EDT 2021

So, the sequence count here is n245008.

But I don't seem to be able to tease out of git(1) an output which shows '245008':

# git rev-list stable/13 --count
256879

# git log --oneline | wc -l
  256879

If git(1) has no equivalent of the svn(1) revision number in the sense
which lets you compare older <--> newer at a glance, how can you tell
that your updated source is actually newer than whatever is installed?

For example, in FreeBSD Security Advisories you could quickly tell the
"good" revision number, but you can't do that by looking at a hash like
'ab3e1bd3c22a222520c23c2793cc39e3a23c9b46'.

-- 
Janos Dohanics



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20210323022500.275ed6e09b1ef0bc59f47af3>