From mboxrd@z Thu Jan 1 00:00:00 1970 From: ludo@gnu.org (Ludovic =?UTF-8?Q?Court=C3=A8s?=) Subject: bug#22017: Pinning a Guix version Date: Thu, 26 Nov 2015 14:30:55 +0100 Message-ID: <87egfcyjjk.fsf@gnu.org> 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]:58608) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1wec-0001LK-90 for bug-guix@gnu.org; Thu, 26 Nov 2015 08:32:07 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1weZ-0006dL-0C for bug-guix@gnu.org; Thu, 26 Nov 2015 08:32:06 -0500 Received: from debbugs.gnu.org ([208.118.235.43]:35538) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1weY-0006dG-Ts for bug-guix@gnu.org; Thu, 26 Nov 2015 08:32:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1a1weY-0003EF-NR for bug-guix@gnu.org; Thu, 26 Nov 2015 08:32:02 -0500 Sender: "Debbugs-submit" Resent-Message-ID: Received: from eggs.gnu.org ([2001:4830:134:3::10]:58236) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1wdY-0001FO-UZ for bug-guix@gnu.org; Thu, 26 Nov 2015 08:31:01 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1wdV-0006PU-MX for bug-guix@gnu.org; Thu, 26 Nov 2015 08:31:00 -0500 Received: from fencepost.gnu.org ([2001:4830:134:3::e]:39232) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1wdV-0006PQ-Jt for bug-guix@gnu.org; Thu, 26 Nov 2015 08:30:57 -0500 Received: from pluto.bordeaux.inria.fr ([193.50.110.57]:47818 helo=pluto) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.82) (envelope-from ) id 1a1wdV-0006Mi-4y for bug-guix@gnu.org; Thu, 26 Nov 2015 08:30:57 -0500 List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org To: 22017@debbugs.gnu.org Hello! In some cases, it=E2=80=99s useful to be able to pin a particular Guix vers= ion and to use that version (see the RepPar paper for some examples.) A naive way to do that is: git clone =E2=80=A6/guix.git my-pinned-guix (cd my-pinned-guix; git checkout deadbeef) guix package -L my-pinned-guix --manifest=3Dmy-manifest.scm However, this is currently broken for several reasons: 1. =E2=80=98fold-packages=E2=80=99 recursively traverses =E2=80=98my-pinn= ed-guix=E2=80=99 for .scm files, and on its way it finds build-aux/build-self.scm, tests/*.scm, and emacs/*.scm, which breaks it all. These directories have to be explicitly removed before we can do something. Internally, =E2=80=98%package-module-path=E2=80=99 can have entries th= at are pairs and where the cdr restricts the search of .scm files to a sub-directory. We should expose that facility to -L and =E2=80=98GUIX_PACKAGE_PATH=E2=80=99 using some special syntax. That way, one could do (say): guix package -L my-pinned-guix,gnu/packages meaning that only the =E2=80=98gnu/packages=E2=80=99 sub-directory is = searched. OTOH, it may be advisable to use the (guix =E2=80=A6) modules from =E2=80=98my-pinned-guix=E2=80=99 and not just the (gnu packages =E2=80= =A6) modules, because the former obviously contribute to the final result. 2. The =E2=80=98gnu/packages/patches=E2=80=99 sub-directory is not automa= tically added to the search path, so in fact one has to run: guix package -L my-pinned-guix \ -L my-pinned-guix/gnu/packages/patches =E2=80=A6 =20=20 so that patches are found. Not convenient. 3. When doing so, we get loads of: ;;; note: source file /tmp/guix/guix/build/perl-build-system.scm ;;; newer than compiled /home/ludo/src/guix/guix/build/perl-buil= d-system.go We should silence Guile. 4. Related to #1: since everything is evaluated, this is ~10 times slower than the normal thing. I think =E2=80=98guix pull=E2=80=99 would be a good place to add support fo= r tagging Guixes and similar, but it would be good if the naive approach above would work just as well. Ludo=E2=80=99.