guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] scripts: environment: Allow mixing regular and ad-hoc packag


From: Ludovic Courtès
Subject: Re: [PATCH] scripts: environment: Allow mixing regular and ad-hoc packages.
Date: Mon, 26 Oct 2015 15:37:52 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.5 (gnu/linux)

David Thompson <address@hidden> skribis:

> Thanks to Leo for bringing up this missing feature on IRC.  I've been
> meaning to implement this for awhile but lacked motivation. ;)
>
> With this patch, you can freely compose packages whose inputs should be
> in the environment with ad-hoc packages that should be added to the
> environment directly.  For example, here's how to create a Guix
> development environment that additionally has strace:
>
>     guix environment guix --ad-hoc strace
>
> The --load and --expression options are --ad-hoc aware as well.  Yay,
> composability!

Swell!

> From 6a1c0b03a0083cc521be5c28a438ed5ecafd2b9d Mon Sep 17 00:00:00 2001
> From: David Thompson <address@hidden>
> Date: Sun, 25 Oct 2015 22:33:33 -0400
> Subject: [PATCH] scripts: environment: Allow mixing regular and ad-hoc
>  packages.
>
> This patch changes the --ad-hoc flag to be positional.  That is, the
> packages that appear before --ad-hoc are interpreted as packages whose
> inputs should be in the environment; the packages that appear after are
> interpreted as packages to be directly added to the environment.
>
> * guix/scripts/environment.scm (tag-package-arg, compact): New
>   procedures.
>   (%options): Tweak the handlers for --load and --expression options.
>   (options/resolve-packages): Preserve package mode tag.
>   (parse-args): Tweak argument handler to use package tagging procedure.
>   (guix-environment): Apply ad-hoc behavior on a per package basis.
> * doc/guix.texi ("invoking guix environment"): Document new behavior of
>   --ad-hoc.

Could you add a test in guix-environment.sh based on the output of
--search-paths, similar to what is already done with ‘gnu-make-boot0’?

Other than that it LGTM!

Thanks,
Ludo’.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]