[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] guix package: Add '--do-not-upgrade' option
From: |
Ludovic Courtès |
Subject: |
Re: [PATCH] guix package: Add '--do-not-upgrade' option |
Date: |
Tue, 14 Apr 2015 11:57:05 +0200 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux) |
Mark H Weaver <address@hidden> skribis:
> This adds a --do-not-upgrade option to 'guix package'.
> One issue is that if you write:
>
> guix package -u --do-not-upgrade icecat
>
> then this will be interpreted as:
>
> guix package -u icecat --do-not-upgrade
>
> The reason is that -u is specified as taking an optional argument, and
> it will take one even if it comes after some other options.
>
> We could fix this by specifying that -u/--upgrade does _not_ take an
> optional argument, instead relying on the 'arg-handler' logic to
> interpret arguments. The downside is that this would no longer be
> allowed:
>
> guix package --upgrade=<pattern>
>
> instead it would have to be written without the '=', like this:
>
> guix package --upgrade <pattern>
>
> What do you think?
I have a slight preference for keeping --upgrade unchanged.
> Anyway, here is my current patch which still has the issue described
> above, so you must write "guix package -u . --do-not-upgrade icecat".
Or “guix package --do-not-upgrade icecat -u”.
> From 1ddc901ae8bbe0bb0b41b380a1f2c1c368602beb Mon Sep 17 00:00:00 2001
> From: Mark H Weaver <address@hidden>
> Date: Thu, 26 Mar 2015 17:25:09 -0400
> Subject: [PATCH] guix package: Add '--do-not-upgrade' option.
>
> * guix/scripts/package.scm (%options): Add the '--do-not-upgrade' option.
> (show-help): Document it.
> (options->installable): Add 'do-not-upgrade-regexps' variable.
> Use it in 'packages-to-upgrade'.
> * doc/guix.texi (Invoking guix package): Document the '--do-not-upgrade'
> option.
Otherwise LGTM. This is a welcome addition!
Thanks,
Ludo’.