aboutsummaryrefslogtreecommitdiff
path: root/src/nix/log.cc
AgeCommit message (Collapse)Author
2020-05-05nix --help: Group commandsEelco Dolstra
2019-12-10Make the Store API more type-safeEelco Dolstra
Most functions now take a StorePath argument rather than a Path (which is just an alias for std::string). The StorePath constructor ensures that the path is syntactically correct (i.e. it looks like <store-dir>/<base32-hash>-<name>). Similarly, functions like buildPaths() now take a StorePathWithOutputs, rather than abusing Path by adding a '!<outputs>' suffix. Note that the StorePath type is implemented in Rust. This involves some hackery to allow Rust values to be used directly in C++, via a helper type whose destructor calls the Rust type's drop() function. The main issue is the dynamic nature of C++ move semantics: after we have moved a Rust value, we should not call the drop function on the original value. So when we move a value, we set the original value to bitwise zero, and the destructor only calls drop() if the value is not bitwise zero. This should be sufficient for most types. Also lots of minor cleanups to the C++ API to make it more modern (e.g. using std::optional and std::string_view in some places).
2019-12-05Make subcommand construction in MultiCommand lazyEelco Dolstra
(cherry picked from commit a0de58f471c9087d8e6cc60a6078f9940a125b15)
2018-01-12nix log: use pagerWill Dietz
2017-09-07nix log: Add examplesEelco Dolstra
2017-09-06nix build: Create result symlinksEelco Dolstra
2017-08-29nix edit / log: Operate on a single InstallableEelco Dolstra
2017-07-30Replace Unicode quotes in user-facing strings by ASCIIJörg Thalheim
Relevant RFC: NixOS/rfcs#4 $ ag -l | xargs sed -i -e "/\"/s/’/'/g;/\"/s/‘/'/g"
2017-07-14Avoid a call to derivationFromPath()Eelco Dolstra
This doesn't work in read-only mode, ensuring that operations like nix path-info --store https://cache.nixos.org -S nixpkgs.hello (asking for the closure size of nixpkgs.hello in cache.nixos.org) work when nixpkgs.hello doesn't exist in the local store.
2017-04-25Move code aroundEelco Dolstra
2017-04-25Restructure installables handling in the "nix" commandEelco Dolstra
2017-03-15Add a "nix log" commandEelco Dolstra
This replaces "nix-store --read-log". It checks the local store and any configured substituters for the requested logs.