Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 30 Dec 2020 13:18:56 -0800 (PST)
From:      "Rodney W. Grimes" <freebsd@gndrsh.dnsmgr.net>
To:        Ryan Libby <rlibby@freebsd.org>
Cc:        Warner Losh <imp@bsdimp.com>, "Rodney W. Grimes" <rgrimes@freebsd.org>, Glen Barber <gjb@freebsd.org>, Kyle Evans <kevans@freebsd.org>, src-committers <src-committers@freebsd.org>, dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org
Subject:   Re: git: 70e64ba44941 - main - release.sh: Update GITROOT URL
Message-ID:  <202012302118.0BULIuGd083574@gndrsh.dnsmgr.net>
In-Reply-To: <CAHgpiFy2UrXeC5k=qUWEdusgGK_4M-mbi%2B9QKTpsteJFyNjeog@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
> On Wed, Dec 30, 2020 at 11:00 AM Warner Losh <imp@bsdimp.com> wrote:
> >
> > On Wed, Dec 30, 2020 at 5:04 AM Rodney W. Grimes <freebsd@gndrsh.dnsmgr.net>
> > wrote:
> <snip>
> > > Now what is being just shoved off as nothing is the fact without
> > > $FreeBSD$ working the ability to backtrace cadence of a file is
> > > going to be a royal pain in the ass, and basically means the project
> > > has "lost" versioning of installed product.
> > >
> >
> > You can commit the file you have to a temporary branch, and use a simple
> > loop to find the file that's closest to it in the main branch with git
> > tools. It's not that hard and covered in several stack trace posts. It's
> > far more reliable than $FreeBSD$ since it will show the version that's the
> > closest to the one you have, in case you moved other later changes in w/o
> > updating $FreeBSD$.
> 
> If there's a need for this, it might be useful to describe in or link
> from the freebsd-git-docs.
> 
> For exact matches, this almost works:
> 
> git describe $(git hash-object $file)
> 
> but not for all branches, I think for git describe $blob you have to be
> on a branch with the blob in history.  It might also come with some
> caveats about the hash format.  We might be able either to add some glue
> around that or work with git upstream.
> 
> Having a tool to find fuzzy matches would be neat (the blob with the
> minimum diff).  Does one exist?

This simply well not easily work.  Let me try to explain why.

First take your self OUT of developer mode, and into operations
and administration.

Take for example all the files in /etc, these files can easily
at present often be tracked back to exactly what release installed
them cause the $FreeBSD$ points you at it.  These files are often
modified by local administrators, and with out knowing what version
they started out it is a crap shoot to ever figure it out unless
the local mods are minor and you get lucky.

Contractors are some times hired to go in and upgrade or clean up
after someone else did work, and not having this information and
telling them to go dig in git to try and figure out the state of
there system is pretty much a non-started, well at least it is for
me.

> 
> Ryan
> 

-- 
Rod Grimes                                                 rgrimes@freebsd.org



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