[Nix-dev] $out in configureFlags is not expanded
Marc Weber
marco-oweber at gmx.de
Tue May 21 14:31:07 CEST 2013
Excerpts from Lluís Batlle i Rossell's message of Tue May 21 14:11:46 +0200 2013:
> > configureFlags = "--whoami-expression=$USER";
> > configureFlags = "--initial-array=( 'state 1' 'state 5' )";
Let's start from scratch:
configureFlags is a list of space separated arguments, right?
So we already have a problem passing "a bc" as one argument!
So we already fail on some cases or is there a way to pass bash arrays
as env vars? (Don't think we want to patch bash)
Thus configureFlags is used the way it is because it works in most
cases.
How to preserve USER if eval would be used? escape the $:
configureFlags = "--whoami-expression=\\$USER";
could be found by try and error fast. so eval would work for almost all
common cases reasnoably well.
If - do we want to happen this rewriting in a build script, or in nix
code if at all?
I personally don't care that much - the way it is works reasnably well,
too.
Marc Weber
More information about the nix-dev
mailing list