diff options
author | Eelco Dolstra <edolstra@gmail.com> | 2017-07-17 19:02:56 +0200 |
---|---|---|
committer | Eelco Dolstra <edolstra@gmail.com> | 2017-07-20 13:33:13 +0200 |
commit | 90825dea518ea078f0783a72cc471a5b3716d198 (patch) | |
tree | b6f6fed6e8c7a96a6769344060409f19a56290b9 /src/nix-env/user-env.cc | |
parent | 3162ad5ff497b92fc25cd3f397eaff01d67340cc (diff) |
Add "nix search" command
Diffstat (limited to 'src/nix-env/user-env.cc')
-rw-r--r-- | src/nix-env/user-env.cc | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/nix-env/user-env.cc b/src/nix-env/user-env.cc index e9997fae5..df5105f12 100644 --- a/src/nix-env/user-env.cc +++ b/src/nix-env/user-env.cc @@ -56,9 +56,10 @@ bool createUserEnv(EvalState & state, DrvInfos & elems, state.mkAttrs(v, 16); mkString(*state.allocAttr(v, state.sType), "derivation"); - mkString(*state.allocAttr(v, state.sName), i.name); - if (!i.system.empty()) - mkString(*state.allocAttr(v, state.sSystem), i.system); + mkString(*state.allocAttr(v, state.sName), i.queryName()); + auto system = i.querySystem(); + if (!system.empty()) + mkString(*state.allocAttr(v, state.sSystem), system); mkString(*state.allocAttr(v, state.sOutPath), i.queryOutPath()); if (drvPath != "") mkString(*state.allocAttr(v, state.sDrvPath), i.queryDrvPath()); |