fetchFrom{Savannah,RepoOrCz,GitLab}: added fetchgit migration helpers
This commit is contained in:
parent
4256ab778a
commit
63c00f2746
@ -375,12 +375,31 @@ let
|
|||||||
inherit sha256;
|
inherit sha256;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# gitorious example
|
||||||
fetchFromGitorious = { owner, repo, rev, sha256, name ? "${repo}-${rev}-src" }: fetchzip {
|
fetchFromGitorious = { owner, repo, rev, sha256, name ? "${repo}-${rev}-src" }: fetchzip {
|
||||||
inherit name;
|
inherit name;
|
||||||
url = "https://gitorious.org/${owner}/${repo}/archive/${rev}.tar.gz";
|
url = "https://gitorious.org/${owner}/${repo}/archive/${rev}.tar.gz";
|
||||||
inherit sha256;
|
inherit sha256;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
# cgit example, snapshot support is optional in cgit
|
||||||
|
fetchFromSavannah = { repo, rev, sha256, name ? "${repo}-${rev}-src" }: fetchzip {
|
||||||
|
inherit name sha256;
|
||||||
|
url = "http://git.savannah.gnu.org/cgit/${repo}.git/snapshot/${repo}-${rev}.tar.gz";
|
||||||
|
};
|
||||||
|
|
||||||
|
# gitlab example
|
||||||
|
fetchFromGitLab = { owner, repo, rev, sha256, name ? "${repo}-${rev}-src" }: fetchzip {
|
||||||
|
inherit name sha256;
|
||||||
|
url = "https://gitlab.com/${owner}/${repo}/repository/archive.tar.gz?ref=${rev}";
|
||||||
|
};
|
||||||
|
|
||||||
|
# gitweb example, snapshot support is optional in gitweb
|
||||||
|
fetchFromRepoOrCz = { repo, rev, sha256, name ? "${repo}-${rev}-src" }: fetchzip {
|
||||||
|
inherit name sha256;
|
||||||
|
url = "http://repo.or.cz/${repo}.git/snapshot/${rev}.tar.gz";
|
||||||
|
};
|
||||||
|
|
||||||
resolveMirrorURLs = {url}: fetchurl {
|
resolveMirrorURLs = {url}: fetchurl {
|
||||||
showURLs = true;
|
showURLs = true;
|
||||||
inherit url;
|
inherit url;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user