This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: Moving to git
- From: "Eric S. Raymond" <esr at thyrsus dot com>
- To: Jonathan Wakely <jwakely dot gcc at gmail dot com>
- Cc: Jakub Jelinek <jakub at redhat dot com>, Jason Merrill <jason at redhat dot com>, Jeff Law <law at redhat dot com>, "gcc at gcc dot gnu dot org" <gcc at gcc dot gnu dot org>
- Date: Mon, 24 Aug 2015 06:42:27 -0400
- Subject: Re: Moving to git
- Authentication-results: sourceware.org; auth=none
- References: <55D61512 dot 8010002 at redhat dot com> <55D61B23 dot 3000309 at redhat dot com> <55D63403 dot 4000603 at redhat dot com> <20150824081741 dot GB9425 at tucnak dot redhat dot com> <CAH6eHdSqG4Y0g7cKjRhwQ=Rv1Syypug0s2v0D118RMeSAzjrFw at mail dot gmail dot com>
- Reply-to: esr at thyrsus dot com
Jonathan Wakely <jwakely.gcc@gmail.com>:
> On 24 August 2015 at 09:17, Jakub Jelinek wrote:
> > The revision ids are also useful for bugzilla, r123456
> > links in text pointing to http://gcc.gnu.org/r123456 is significantly
> > shorter
>
> The first six characters of the sha1 is usually enough to
> unambiguously identify a commit, so we could easily have
> https://gcc.gnu.org/git/f00baa or something similar, if we don't use
> git-notes to add a revision to the commits.
I recommend *against* using hashes to identify commits. Here's what I said
about it in the NTPsec developers guidelines.
=== How to refer to previous commits ===
The best (most human-friendly) way to reference a commit is by quoting its
summary line. If you need to disambiguate, give its date and author.
The worst way is to quote its git hash, because humans are not good at
keeping random strings of hex digits in working memory. Besides, hashes
will break if the history is ever moved to another VCS or the repository
has to be surgically altered.
--
<a href="http://www.catb.org/~esr/">Eric S. Raymond</a>