aboutsummaryrefslogtreecommitdiff
path: root/src/nix
diff options
context:
space:
mode:
authorJohn Ericson <John.Ericson@Obsidian.Systems>2020-10-06 04:20:44 +0000
committerJohn Ericson <John.Ericson@Obsidian.Systems>2020-10-06 04:20:44 +0000
commitdae4409071b827a539acd0f46f91f15cfa1e1a7d (patch)
treefd3a59d28da3481aebb76353bb630f090125769c /src/nix
parent45ca7c3e4b92bbafbfa8e30513c9dd3cfe76e3f1 (diff)
parent88a667e49e10af4a9e2daa51badbed63ad19d817 (diff)
Merge remote-tracking branch 'upstream/master' into path-info
Diffstat (limited to 'src/nix')
-rw-r--r--src/nix/command.cc2
-rw-r--r--src/nix/hash.cc1
-rw-r--r--src/nix/registry.cc4
-rw-r--r--src/nix/run.cc8
4 files changed, 12 insertions, 3 deletions
diff --git a/src/nix/command.cc b/src/nix/command.cc
index 37a4bc785..ba7de9fdd 100644
--- a/src/nix/command.cc
+++ b/src/nix/command.cc
@@ -152,7 +152,7 @@ void MixProfile::updateProfile(const Buildables & buildables)
for (auto & output : bfd.outputs) {
/* Output path should be known because we just tried to
build it. */
- assert(!output.second);
+ assert(output.second);
result.push_back(*output.second);
}
},
diff --git a/src/nix/hash.cc b/src/nix/hash.cc
index 0eca4f8ea..494f00a20 100644
--- a/src/nix/hash.cc
+++ b/src/nix/hash.cc
@@ -44,6 +44,7 @@ struct CmdHash : Command
switch (mode) {
case FileIngestionMethod::Flat:
d = "print cryptographic hash of a regular file";
+ break;
case FileIngestionMethod::Recursive:
d = "print cryptographic hash of the NAR serialisation of a path";
};
diff --git a/src/nix/registry.cc b/src/nix/registry.cc
index 367268683..cb11ec195 100644
--- a/src/nix/registry.cc
+++ b/src/nix/registry.cc
@@ -31,8 +31,8 @@ struct CmdRegistryList : StoreCommand
registry->type == Registry::User ? "user " :
registry->type == Registry::System ? "system" :
"global",
- entry.from.to_string(),
- entry.to.to_string());
+ entry.from.toURLString(),
+ entry.to.toURLString(attrsToQuery(entry.extraAttrs)));
}
}
}
diff --git a/src/nix/run.cc b/src/nix/run.cc
index cbaba9d90..e6584346e 100644
--- a/src/nix/run.cc
+++ b/src/nix/run.cc
@@ -167,6 +167,14 @@ struct CmdRun : InstallableCommand, RunCommon
"To run Blender:",
"nix run blender-bin"
},
+ Example{
+ "To run vim from nixpkgs:",
+ "nix run nixpkgs#vim"
+ },
+ Example{
+ "To run vim from nixpkgs with arguments:",
+ "nix run nixpkgs#vim -- --help"
+ },
};
}