add build-channel command

This commit is contained in:
Jörg Thalheim 2018-08-11 14:09:33 +02:00
parent 475851ada5
commit 93f7c23f2f
9 changed files with 217 additions and 37 deletions

View file

@ -17,8 +17,12 @@ let
revision = lockedRevisions.${name};
submodules = attr.submodules or false;
type = attr.type or null;
localPath = ../repos + "/${name}";
in
if lib.hasPrefix "https://github.com" attr.url && !submodules then
if lib.pathExists localPath then
localPath
else if lib.hasPrefix "https://github.com" attr.url && !submodules then
fetchzip {
url = "${attr.url}/archive/${revision.rev}.zip";
inherit (revision) sha256;