lix/src/libfetchers
Eelco Dolstra 12f9379123 Add 'path' fetcher
This fetchers copies a plain directory (i.e. not a Git/Mercurial
repository) to the store (or does nothing if the path is already a
store path).

One use case is to pin the 'nixpkgs' flake used to build the current
NixOS system, and prevent it from being garbage-collected, via a
system registry entry like this:

  {
      "from": {
          "id": "nixpkgs",
          "type": "indirect"
      },
      "to": {
          "type": "path",
          "path": "/nix/store/rralhl3wj4rdwzjn16g7d93mibvlr521-source",
          "lastModified": 1585388205,
          "rev": "b0c285807d6a9f1b7562ec417c24fa1a30ecc31a"
      },
      "exact": true
  }

Note the fake "lastModified" and "rev" attributes that ensure that the
flake gives the same evaluation results as the corresponding
Git/GitHub inputs.
2020-04-02 14:56:20 +02:00
..
attrs.cc Add 'path' fetcher 2020-04-02 14:56:20 +02:00
attrs.hh Add 'path' fetcher 2020-04-02 14:56:20 +02:00
cache.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
cache.hh Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
fetchers.cc nix flake info --json: Show TreeInfo 2020-04-02 11:51:34 +02:00
fetchers.hh Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
git.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
github.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
indirect.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
local.mk Remove global -I flags 2020-03-30 14:39:33 +02:00
mercurial.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
path.cc Add 'path' fetcher 2020-04-02 14:56:20 +02:00
registry.cc Support registry entries that must match exactly 2020-04-01 23:12:45 +02:00
registry.hh Support registry entries that must match exactly 2020-04-01 23:12:45 +02:00
tarball.cc Move fetchers from libstore to libfetchers 2020-03-30 14:04:53 +02:00
tree-info.cc Doh 2020-04-02 11:55:41 +02:00
tree-info.hh nix flake info --json: Show TreeInfo 2020-04-02 11:51:34 +02:00