nixpkgs-suyu/pkgs/applications/version-management/sourcehut/hg.nix

44 lines
821 B
Nix
Raw Normal View History

2021-04-18 05:15:43 +02:00
{ lib
, fetchhg
, buildPythonPackage
, srht
, hglib
, scmsrht
, unidiff
, python
}:
buildPythonPackage rec {
pname = "hgsrht";
2021-12-28 22:26:56 +01:00
version = "0.29.3";
src = fetchhg {
url = "https://hg.sr.ht/~sircmpwn/hg.sr.ht";
rev = version;
2021-12-28 22:26:56 +01:00
sha256 = "y8gKaamwD5lsYqO1SkxMcn3E2TWidHAo2slvEU+8ovg=";
};
nativeBuildInputs = srht.nativeBuildInputs;
propagatedBuildInputs = [
srht
hglib
scmsrht
unidiff
];
preBuild = ''
export PKGVER=${version}
2021-04-18 05:15:43 +02:00
export SRHT_PATH=${srht}/${python.sitePackages}/srht
'';
2021-08-15 23:11:47 +02:00
pythonImportsCheck = [ "hgsrht" ];
meta = with lib; {
homepage = "https://git.sr.ht/~sircmpwn/hg.sr.ht";
description = "Mercurial repository hosting service for the sr.ht network";
2021-08-15 22:54:11 +02:00
license = licenses.agpl3Only;
maintainers = with maintainers; [ eadwu ];
};
}