Merge pull request #39467 from typetetris/master

fetchFromGitLab: Use API archive download endpoint.
This commit is contained in:
Matthew Justin Bauer 2018-05-01 10:21:41 -05:00 committed by GitHub
commit 587112b7dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -288,7 +288,7 @@ with pkgs;
... # For hash agility
}@args: fetchzip ({
inherit name;
url = "https://gitlab.com/${owner}/${repo}/-/archive/${rev}/${repo}-${rev}.tar.gz";
url = "https://gitlab.com/api/v4/projects/${owner}%2F${repo}/repository/archive.tar.gz?sha=${rev}";
meta.homepage = "https://gitlab.com/${owner}/${repo}/";
} // removeAttrs args [ "owner" "repo" "rev" ]) // { inherit rev; };