diff --git a/pkgs/build-support/fetchgitea/default.nix b/pkgs/build-support/fetchgitea/default.nix new file mode 100644 index 00000000000..79804588cfe --- /dev/null +++ b/pkgs/build-support/fetchgitea/default.nix @@ -0,0 +1,7 @@ +# Gitea's URLs are compatible with GitHub + +{ lib, fetchFromGitHub }: + +{ domain, ... }@args: + +fetchFromGitHub ((removeAttrs args [ "domain" ]) // { githubBase = domain; }) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 34540ed59b1..4c5c0b454db 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -556,6 +556,8 @@ in fetchCrate = callPackage ../build-support/rust/fetchcrate.nix { }; + fetchFromGitea = callPackage ../build-support/fetchgitea { }; + fetchFromGitHub = callPackage ../build-support/fetchgithub {}; fetchFromBitbucket = callPackage ../build-support/fetchbitbucket {};