From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?utf-8?Q?Court=C3=A8s?=) Subject: Re: [PATCH] guix hash: -g hashes a git repository Date: Wed, 05 Apr 2017 23:06:02 +0200 Message-ID: <8760iimuo5.fsf@gnu.org> References: <20170403195837.4504-1-wingo@igalia.com> <87o9wcs6qs.fsf@gnu.org> <87k2708edb.fsf@igalia.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:50661) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cvs80-0002qm-2u for guix-devel@gnu.org; Wed, 05 Apr 2017 17:06:09 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cvs7w-0003vF-UM for guix-devel@gnu.org; Wed, 05 Apr 2017 17:06:08 -0400 In-Reply-To: <87k2708edb.fsf@igalia.com> (Andy Wingo's message of "Tue, 04 Apr 2017 15:57:20 +0200") List-Id: "Development of GNU Guix and the GNU System distribution." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-devel-bounces+gcggd-guix-devel=m.gmane.org@gnu.org Sender: "Guix-devel" To: Andy Wingo Cc: guix-devel@gnu.org Andy Wingo skribis: > On Tue 04 Apr 2017 14:21, ludo@gnu.org (Ludovic Court=C3=A8s) writes: > >>> +For example: >>> +@example >>> +$ git clone http://example.org/foo.git >>> +$ guix hash -g foo >>> +@end example >> >> In this case -g is equivalent to -rx. > > My main use case is when I am in a git checkout that has build products > or other stuff. Then I can "guix hash -g .". Easier than making a temp > dir, clone, hash, then delete. Oh right, I hadn't realized that it would exclude untracked files etc. Definitely an improvement! > > so we have both the commit id and the content hash. > > > > WDYT? > > Could be! Or "git rev-parse HEAD". I'll do that. Awesome. Thanks, Ludo=E2=80=99.