From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934031Ab0J1R1g (ORCPT ); Thu, 28 Oct 2010 13:27:36 -0400 Received: from thunk.org ([69.25.196.29]:37155 "EHLO thunker.thunk.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S933260Ab0J1R1a (ORCPT ); Thu, 28 Oct 2010 13:27:30 -0400 Date: Thu, 28 Oct 2010 13:27:25 -0400 From: "Ted Ts'o" To: Ingo Molnar Cc: Linus Torvalds , git@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Minimum git commit abbrev length (Was Re: -tip: origin tree build failure (was: [GIT PULL] ext4 update) for 2.6.37) Message-ID: <20101028172725.GA6814@thunk.org> Mail-Followup-To: Ted Ts'o , Ingo Molnar , Linus Torvalds , git@vger.kernel.org, linux-kernel@vger.kernel.org References: <20101028075631.GA7690@elte.hu> <20101028163854.GA15450@elte.hu> <20101028171701.GA18368@elte.hu> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20101028171701.GA18368@elte.hu> User-Agent: Mutt/1.5.20 (2009-06-14) X-SA-Exim-Connect-IP: X-SA-Exim-Mail-From: tytso@thunk.org X-SA-Exim-Scanned: No (on thunker.thunk.org); SAEximRunCond expanded to false Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Oct 28, 2010 at 07:17:01PM +0200, Ingo Molnar wrote: > > Linus Torvalds wrote: > > Yes. Except for the kernel the default git commit abbreviation is > > borderline too short. Seven hex-chars can easily alias with a few > > more pulls from me: git will not give aliases at the time it gives > > a shorthand, but a month or two later the abbreviated commit may > > no longer be unique. > > > > So I suggest using --abbrev=12 or similar. > > ok. A helper script i use does this: > > git log --pretty=format:"%h: %s" $@ > > I have added --abbrev=12. Might make sense to lengthen the %h > default in upstream Git as well? Maybe the right thing to do is add a git config option which allows for a configurable minimum git commit abbreviation length? - Ted