1
0
Fork 0
mirror of https://github.com/NixOS/nix synced 2025-07-02 21:51:50 +02:00

Use ^ not ! in indexed store derivations installable syntax

Match the other syntax that was recently added
This commit is contained in:
John Ericson 2022-05-12 20:10:02 +00:00
parent b18720ee17
commit 49ad315c03
5 changed files with 13 additions and 14 deletions

View file

@ -799,11 +799,12 @@ std::vector<std::shared_ptr<Installable>> SourceExprCommand::parseInstallables(
for (auto & s : ss) {
std::exception_ptr ex;
if (s.rfind('!') != std::string::npos) {
auto found = s.rfind('^');
if (found != std::string::npos) {
try {
result.push_back(std::make_shared<InstallableIndexedStorePath>(
store,
DerivedPath::Built::parse(*store, s)));
DerivedPath::Built::parse(*store, s.substr(0, found), s.substr(found + 1))));
settings.requireExperimentalFeature(Xp::ComputedDerivations);
continue;
} catch (BadStorePath &) {
@ -813,7 +814,8 @@ std::vector<std::shared_ptr<Installable>> SourceExprCommand::parseInstallables(
}
}
if (s.find('/') != std::string::npos) {
found = s.find('/');
if (found != std::string::npos) {
try {
result.push_back(std::make_shared<InstallableStorePath>(store, store->followLinksToStorePath(s)));
continue;