From: Shea Levy <shea@shealevy.com>
To: "Ludovic Courtès" <ludo@gnu.org>
Cc: guix-devel <guix-devel@gnu.org>, nix-dev <nix-dev@lists.science.uu.nl>
Subject: Re: [PATCH]
Date: Mon, 14 Apr 2014 09:45:03 -0400 [thread overview]
Message-ID: <20140414134503.GA5378@nixos> (raw)
In-Reply-To: <878ur8jakm.fsf@gnu.org>
Hi Ludo’,
On Mon, Apr 14, 2014 at 03:38:01PM +0200, Ludovic Courtès wrote:
> The patch below allows files such as /nix/store/foo to be protected from
> GC if a root refers to them. This makes it easy for a build hook to use
> such files for its temporary working files.
>
> WDYT?
>
It seems a bit odd to me to be using the store as a temporary file
location. What's wrong with $TMPDIR?
>
> Thanks,
> Ludo’.
>
> diff --git a/src/libstore/gc.cc b/src/libstore/gc.cc
> index 96e891f..299bf5f 100644
> --- a/src/libstore/gc.cc
> +++ b/src/libstore/gc.cc
> @@ -287,10 +287,7 @@ static void foundRoot(StoreAPI & store,
> const Path & path, const Path & target, Roots & roots)
> {
> Path storePath = toStorePath(target);
> - if (store.isValidPath(storePath))
Hm, don't we at least want to check that it's in the store at all?
>
> roots[path] = storePath;
> - else
> - printMsg(lvlInfo, format("skipping invalid root from `%1%' to `%2%'") % path % storePath);
> }
~Shea
> _______________________________________________
> nix-dev mailing list
> nix-dev@lists.science.uu.nl
> http://lists.science.uu.nl/mailman/listinfo/nix-dev
_______________________________________________
nix-dev mailing list
nix-dev@lists.science.uu.nl
http://lists.science.uu.nl/mailman/listinfo/nix-dev
next prev parent reply other threads:[~2014-04-14 13:45 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-04-14 13:38 [PATCH] Ludovic Courtès
2014-04-14 13:45 ` Shea Levy [this message]
2014-04-14 14:45 ` [PATCH] Allow roots to refer to arbitrary files in the store Ludovic Courtès
2014-04-14 14:59 ` Ludovic Courtès
2014-04-15 13:11 ` Shea Levy
2014-04-15 19:34 ` Ludovic Courtès
[not found] ` <534D3898.7000503@logicblox.com>
2014-04-15 20:11 ` Ludovic Courtès
-- strict thread matches above, loose matches on Subject: below --
2016-08-07 16:18 [PATCH] ng0
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=20140414134503.GA5378@nixos \
--to=shea@shealevy.com \
--cc=guix-devel@gnu.org \
--cc=ludo@gnu.org \
--cc=nix-dev@lists.science.uu.nl \
/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.