mirror of
https://github.com/NixOS/nix
synced 2025-06-25 06:31:14 +02:00
Merge all nix-* binaries into nix
These are all symlinks to 'nix' now, reducing the installed size by about ~1.7 MiB.
This commit is contained in:
parent
c47e14ee45
commit
f6a3dfe4e0
24 changed files with 105 additions and 165 deletions
|
@ -6,6 +6,7 @@
|
|||
#include "eval-inline.hh"
|
||||
#include "common-eval-args.hh"
|
||||
#include "attr-path.hh"
|
||||
#include "legacy.hh"
|
||||
|
||||
#include <iostream>
|
||||
|
||||
|
@ -44,12 +45,9 @@ string resolveMirrorUri(EvalState & state, string uri)
|
|||
}
|
||||
|
||||
|
||||
int main(int argc, char * * argv)
|
||||
static int _main(int argc, char * * argv)
|
||||
{
|
||||
return handleExceptions(argv[0], [&]() {
|
||||
initNix();
|
||||
initGC();
|
||||
|
||||
{
|
||||
HashType ht = htSHA256;
|
||||
std::vector<string> args;
|
||||
bool printPath = getEnv("PRINT_PATH") != "";
|
||||
|
@ -221,5 +219,9 @@ int main(int argc, char * * argv)
|
|||
std::cout << printHash16or32(hash) << std::endl;
|
||||
if (printPath)
|
||||
std::cout << storePath << std::endl;
|
||||
});
|
||||
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
|
||||
static RegisterLegacyCommand s1("nix-prefetch-url", _main);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue