From: ludo@gnu.org (Ludovic Courtès)
To: Mark H Weaver <mhw@netris.org>
Cc: bug-guix@gnu.org
Subject: Re: [PATCH] Implement guix-package --upgrade
Date: Tue, 12 Feb 2013 10:50:12 +0100 [thread overview]
Message-ID: <87a9r9zwrv.fsf@gnu.org> (raw)
In-Reply-To: <87vc9yxcre.fsf@tines.lan> (Mark H. Weaver's message of "Tue, 12 Feb 2013 01:33:09 -0500")
Hi Mark!
Mark H Weaver <mhw@netris.org> skribis:
> Here's an implementation of the -u/--upgrade option for guix-package.
Nice!
> + (upgrade (if (null? upgrade-regexps)
> + '()
> + (filter-map (match-lambda
> + ((name _ _ _ _)
> + (and (any (cut regexp-exec <> name)
> + upgrade-regexps)
> + (find-package name)))
> + (_ #f))
> + installed)))
It’s actually slightly more complex: you need to select those packages
that are installed and for which either a newer version is available
(per ‘version-string>?’, see gnu-maintenance.scm; should be moved to
utils.scm), or the version is identical and the output path differs (for
instance because one of its dependencies has changed.)
There are tests in guix-package.sh, but this one is going to be
difficult to test without building the world.
I think guix-package needs a -e switch (as for guix-build), which would
allow us to write dummy packages for test purposes.
WDYT?
Ludo’.
next prev parent reply other threads:[~2013-02-12 9:50 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-12 6:33 [PATCH] Implement guix-package --upgrade Mark H Weaver
2013-02-12 9:50 ` Ludovic Courtès [this message]
2013-02-12 10:04 ` Andreas Enge
2013-02-12 10:08 ` Ludovic Courtès
2013-02-12 14:27 ` Mark H Weaver
2013-02-12 15:16 ` Ludovic Courtès
2013-02-12 19:29 ` Mark H Weaver
2013-02-12 19:55 ` Mark H Weaver
2013-02-12 21:04 ` Andreas Enge
2013-02-12 21:42 ` Ludovic Courtès
2013-02-13 10:56 ` [PATCH] Build newest versions unless specified, and upgrades Mark H Weaver
2013-02-13 11:40 ` Mark H Weaver
2013-02-13 21:04 ` Ludovic Courtès
2013-02-14 4:57 ` Mark H Weaver
2013-02-12 21:41 ` [PATCH] Implement guix-package --upgrade Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=87a9r9zwrv.fsf@gnu.org \
--to=ludo@gnu.org \
--cc=bug-guix@gnu.org \
--cc=mhw@netris.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/guix.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.