From owner-dev-commits-src-main@freebsd.org Wed Dec 30 21:18:59 2020 Return-Path: Delivered-To: dev-commits-src-main@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 4B2D84CF4D5; Wed, 30 Dec 2020 21:18:59 +0000 (UTC) (envelope-from freebsd@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (br1.CN84in.dnsmgr.net [69.59.192.140]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4D5kg66XSGz4gjQ; Wed, 30 Dec 2020 21:18:58 +0000 (UTC) (envelope-from freebsd@gndrsh.dnsmgr.net) Received: from gndrsh.dnsmgr.net (localhost [127.0.0.1]) by gndrsh.dnsmgr.net (8.13.3/8.13.3) with ESMTP id 0BULIuow083575; Wed, 30 Dec 2020 13:18:56 -0800 (PST) (envelope-from freebsd@gndrsh.dnsmgr.net) Received: (from freebsd@localhost) by gndrsh.dnsmgr.net (8.13.3/8.13.3/Submit) id 0BULIuGd083574; Wed, 30 Dec 2020 13:18:56 -0800 (PST) (envelope-from freebsd) From: "Rodney W. Grimes" Message-Id: <202012302118.0BULIuGd083574@gndrsh.dnsmgr.net> Subject: Re: git: 70e64ba44941 - main - release.sh: Update GITROOT URL In-Reply-To: To: Ryan Libby Date: Wed, 30 Dec 2020 13:18:56 -0800 (PST) CC: Warner Losh , "Rodney W. Grimes" , Glen Barber , Kyle Evans , src-committers , dev-commits-src-all@freebsd.org, dev-commits-src-main@freebsd.org Reply-To: rgrimes@freebsd.org X-Mailer: ELM [version 2.4ME+ PL121h (25)] MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=US-ASCII X-Rspamd-Queue-Id: 4D5kg66XSGz4gjQ X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[] X-BeenThere: dev-commits-src-main@freebsd.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: "Commit messages for the main branch of the src repository." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 30 Dec 2020 21:18:59 -0000 > On Wed, Dec 30, 2020 at 11:00 AM Warner Losh wrote: > > > > On Wed, Dec 30, 2020 at 5:04 AM Rodney W. Grimes > > wrote: > > > > 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