Skip to content

Commit

Permalink
update sources
Browse files Browse the repository at this point in the history
  • Loading branch information
BrianHicks committed Jan 17, 2020
1 parent 7ce64c2 commit 140a7c0
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 17 deletions.
24 changes: 12 additions & 12 deletions nix/sources.json
Expand Up @@ -96,10 +96,10 @@
"kakoune": "plugin",
"owner": "alexherbo2",
"repo": "connect.kak",
"rev": "27c954775038787e56250d83c621767f13a4d209",
"sha256": "1bdds341blq8i90g044m2n6zw5jagwv43fh6cfrvkkx3r1rrhxwg",
"rev": "fdf9b76fccc1d9e69a3028f38424c853482bba03",
"sha256": "1k9l23y4wrqwzsrzlbcmkxpdjskia3k6bphdjcvri01ww6ql01pc",
"type": "tarball",
"url": "https://github.com/alexherbo2/connect.kak/archive/27c954775038787e56250d83c621767f13a4d209.tar.gz",
"url": "https://github.com/alexherbo2/connect.kak/archive/fdf9b76fccc1d9e69a3028f38424c853482bba03.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"delimitMate": {
Expand Down Expand Up @@ -277,10 +277,10 @@
"homepage": "https://github.com/nmattia/niv",
"owner": "nmattia",
"repo": "niv",
"rev": "c8f74f44b5f5df2c8f20a1834460d012e74d78f9",
"sha256": "0zmhxgl37f1p2aiqjmiccflpgga6phj6vmqs3jd33z0frj6hsy5c",
"rev": "61b61d1e5f8096fe65fb825bec23f33e861c51d0",
"sha256": "1dwfkd942wisccpsv0kf47abl0n17d9v4zasv4bm8lvy1dhv82ia",
"type": "tarball",
"url": "https://github.com/nmattia/niv/archive/c8f74f44b5f5df2c8f20a1834460d012e74d78f9.tar.gz",
"url": "https://github.com/nmattia/niv/archive/61b61d1e5f8096fe65fb825bec23f33e861c51d0.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz"
},
"nixfmt": {
Expand Down Expand Up @@ -494,10 +494,10 @@
"homepage": "https://github.com/tpope/vim-eunuch",
"owner": "tpope",
"repo": "vim-eunuch",
"rev": "75efe06ccc63b7cd50b193b99cce83e3ad3e60cb",
"sha256": "0yjsk6amlbgdbp95h8fp4x1hf9gmrfgrvz9gizyh08xdrb7pbpdw",
"rev": "33e875b31c8b811a0a47908884a5e2339106bbe8",
"sha256": "1xadb22kd40swmww0qxmmkcpcq6viy8l167pjck5q32hfngll5d3",
"type": "tarball",
"url": "https://github.com/tpope/vim-eunuch/archive/75efe06ccc63b7cd50b193b99cce83e3ad3e60cb.tar.gz",
"url": "https://github.com/tpope/vim-eunuch/archive/33e875b31c8b811a0a47908884a5e2339106bbe8.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz",
"vim": "true"
},
Expand Down Expand Up @@ -624,10 +624,10 @@
"homepage": "https://github.com/tpope/vim-rails",
"owner": "tpope",
"repo": "vim-rails",
"rev": "7732c0a3c3cac92d5276496f6055815b7b745ac5",
"sha256": "0a3wfqynhlca75adgf00n3dp1kg8ly7haasg7a2v4adqh5ckmvfj",
"rev": "64befc6187678893082bebb8be79c1d17fdd07ba",
"sha256": "1yjqxqx3g74afzdq8iqd6zw7ypn6dv1i14qi9a7jnnwnp956lc12",
"type": "tarball",
"url": "https://github.com/tpope/vim-rails/archive/7732c0a3c3cac92d5276496f6055815b7b745ac5.tar.gz",
"url": "https://github.com/tpope/vim-rails/archive/64befc6187678893082bebb8be79c1d17fdd07ba.tar.gz",
"url_template": "https://github.com/<owner>/<repo>/archive/<rev>.tar.gz",
"vim": "true"
},
Expand Down
12 changes: 7 additions & 5 deletions nix/sources.nix
Expand Up @@ -19,7 +19,7 @@ let
pkgs.fetchzip { inherit (spec) url sha256; };

fetch_git = spec:
builtins.fetchGit { url = spec.repo; inherit (spec) rev ref; };
builtins.fetchGit { url = spec.repo; inherit (spec) rev ref; };

fetch_builtin-tarball = spec:
builtins.trace
Expand Down Expand Up @@ -125,12 +125,14 @@ let
# The "config" used by the fetchers
mkConfig =
{ sourcesFile ? ./sources.json
, sources ? builtins.fromJSON (builtins.readFile sourcesFile)
, pkgs ? mkPkgs sources
}: rec {
# The sources, i.e. the attribute set of spec name to spec
sources = builtins.fromJSON (builtins.readFile sourcesFile);
inherit sources;

# The "pkgs" (evaluated nixpkgs) to use for e.g. non-builtin fetchers
pkgs = mkPkgs sources;
inherit pkgs;
};
in
mkSources (mkConfig {}) //
{ __functor = _: settings: mkSources (mkConfig settings); }
mkSources (mkConfig {}) // { __functor = _: settings: mkSources (mkConfig settings); }

0 comments on commit 140a7c0

Please sign in to comment.