GNU bug report logs - #33522
[PATCH 0/3] Add the '--with-branch' package transformation option

Previous Next

Package: guix-patches;

Reported by: Ludovic Courtès <ludo <at> gnu.org>

Date: Tue, 27 Nov 2018 15:33:02 UTC

Severity: normal

Tags: patch

Done: ludovic.courtes <at> inria.fr (Ludovic Courtès)

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (GNU bug Tracking System)
To: ludovic.courtes <at> inria.fr (Ludovic Courtès)
Cc: tracker <at> debbugs.gnu.org
Subject: bug#33522: closed ([PATCH 0/3] Add the '--with-branch' package
 transformation option)
Date: Fri, 30 Nov 2018 16:05:02 +0000
[Message part 1 (text/plain, inline)]
Your message dated Fri, 30 Nov 2018 17:04:48 +0100
with message-id <871s72wnz3.fsf <at> gnu.org>
and subject line Re: [bug#33522] [PATCH 0/3] Add the '--with-branch' package transformation option
has caused the debbugs.gnu.org bug report #33522,
regarding [PATCH 0/3] Add the '--with-branch' package transformation option
to be marked as done.

(If you believe you have received this mail in error, please contact
help-debbugs <at> gnu.org.)


-- 
33522: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=33522
GNU Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Ludovic Courtès <ludo <at> gnu.org>
To: guix-patches <at> gnu.org
Cc: Ludovic Courtès <ludo <at> gnu.org>
Subject: [PATCH 0/3] Add the '--with-branch' package transformation option
Date: Tue, 27 Nov 2018 16:31:47 +0100
Hello,

This patch series adds a ‘git-checkout’ file-like construct along with
a ‘--with-branch’ package transformation option.

The ‘git-checkout’ construct may be used like this:

  (define-public guile-git
    (package
      (inherit guile-next)
      (version "git")
      (source (git-checkout
               (url "https://git.savannah.gnu.org/git/guile.git")
               (branch "master")))))

Then you can do this:

--8<---------------cut here---------------start------------->8---
$ guix build -L ~/.config/guix/personal/ guile-next <at> git
updating checkout of 'https://git.savannah.gnu.org/git/guile.git'...
retrieved commit 1f6786db06fee5f0bbdbd637acc6aa46aecd4169
building /gnu/store/7l168l4lgpjjg9jq7lh2416cc884r3s9-guile-next-git.drv...
[…]
--8<---------------cut here---------------end--------------->8---

IOW, every time you build the package, it gets built off the latest
commit of the specified branch.

The next patch add ‘--with-branch’ which makes that functionality
available from the command line.  For example:

  guix build --with-branch=guile-gcrypt=master cuirass

builds the latest guile-gcrypt, guix, and cuirass, using the latest
guile-gcrypt commit on ‘master’.

The ‘--with-branch’ option only works with packages that have a
‘git-fetch’ origin or a ‘git-checkout’ as their source.

I find it rather neat.  WDYT?  :-)

Ludo’.

Ludovic Courtès (3):
  git: 'latest-repository-commit' logs its progress.
  git: Add <git-checkout> record type.
  guix build: Add '--with-branch' transformation option.

 Makefile.am                |  1 +
 doc/guix.texi              | 27 ++++++++++++++++++
 guix/git.scm               | 41 ++++++++++++++++++++++++++--
 guix/scripts/build.scm     | 56 ++++++++++++++++++++++++++++++++++++--
 tests/guix-build-branch.sh | 48 ++++++++++++++++++++++++++++++++
 5 files changed, 168 insertions(+), 5 deletions(-)
 create mode 100644 tests/guix-build-branch.sh

-- 
2.19.2



[Message part 3 (message/rfc822, inline)]
From: ludovic.courtes <at> inria.fr (Ludovic Courtès)
To: 33522-done <at> debbugs.gnu.org
Subject: Re: [bug#33522] [PATCH 0/3] Add the '--with-branch' package
 transformation option
Date: Fri, 30 Nov 2018 17:04:48 +0100
Hi there!

Ludovic Courtès <ludo <at> gnu.org> skribis:

> Ludovic Courtès (3):
>   git: 'latest-repository-commit' logs its progress.
>   git: Add <git-checkout> record type.
>   guix build: Add '--with-branch' transformation option.

I pushed these 3 commits and added a 4th one that implements
‘--with-commit’ along the same lines.

Enjoy!

Ludo’.


This bug report was last modified 6 years and 178 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.