mirror of
https://github.com/NixOS/nix
synced 2025-07-03 02:01:48 +02:00
nix-build.cc: Refactor: extract sourcePath, resolvedPath variables
This commit is contained in:
parent
e9479b272f
commit
76245ffbeb
1 changed files with 5 additions and 5 deletions
|
@ -315,11 +315,11 @@ static void main_nix_build(int argc, char * * argv)
|
||||||
relative to the script. */
|
relative to the script. */
|
||||||
auto baseDir = inShebang && !packages ? absPath(i, absPath(dirOf(script))) : i;
|
auto baseDir = inShebang && !packages ? absPath(i, absPath(dirOf(script))) : i;
|
||||||
|
|
||||||
exprs.push_back(
|
auto sourcePath = lookupFileArg(*state,
|
||||||
state->parseExprFromFile(
|
baseDir);
|
||||||
resolveExprPath(
|
auto resolvedPath = resolveExprPath(sourcePath);
|
||||||
lookupFileArg(*state,
|
|
||||||
baseDir))));
|
exprs.push_back(state->parseExprFromFile(resolvedPath));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue