2021-11-19 15:25:21 +00:00
|
|
|
|
{ lib
|
|
|
|
|
, buildPythonApplication
|
|
|
|
|
, fetchPypi
|
|
|
|
|
, mercurial
|
|
|
|
|
# build inputs
|
|
|
|
|
, distro
|
|
|
|
|
, glean-sdk
|
|
|
|
|
, python-hglib
|
|
|
|
|
, sentry-sdk
|
|
|
|
|
, setuptools
|
|
|
|
|
}:
|
2021-11-17 17:30:53 +00:00
|
|
|
|
|
2021-11-19 15:25:21 +00:00
|
|
|
|
buildPythonApplication rec {
|
2021-11-19 17:25:50 +00:00
|
|
|
|
pname = "moz-phab";
|
2021-11-17 17:30:53 +00:00
|
|
|
|
version = "0.1.99";
|
|
|
|
|
|
2021-11-19 15:25:21 +00:00
|
|
|
|
src = fetchPypi {
|
2021-11-19 17:25:50 +00:00
|
|
|
|
pname = "MozPhab";
|
|
|
|
|
inherit version;
|
2021-11-17 17:30:53 +00:00
|
|
|
|
sha256 = "sha256-uKoMMSp5AIvB1qTRYAh7n1+2dDLneFbssfkfTTshfcs=";
|
|
|
|
|
};
|
|
|
|
|
|
2021-11-25 16:18:07 +00:00
|
|
|
|
# Relax python-hglib requirement
|
|
|
|
|
# https://phabricator.services.mozilla.com/D131618
|
|
|
|
|
postPatch = ''
|
|
|
|
|
substituteInPlace setup.py \
|
|
|
|
|
--replace "==" ">="
|
|
|
|
|
'';
|
2021-11-19 15:25:21 +00:00
|
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
2021-11-17 17:30:53 +00:00
|
|
|
|
distro
|
|
|
|
|
glean-sdk
|
|
|
|
|
python-hglib
|
|
|
|
|
sentry-sdk
|
|
|
|
|
setuptools
|
|
|
|
|
];
|
2021-11-19 15:25:21 +00:00
|
|
|
|
checkInputs = [
|
|
|
|
|
mercurial
|
2021-11-17 17:30:53 +00:00
|
|
|
|
];
|
|
|
|
|
|
2021-11-19 15:25:21 +00:00
|
|
|
|
preCheck = ''
|
|
|
|
|
export HOME=$(mktemp -d)
|
|
|
|
|
'';
|
2021-11-17 17:30:53 +00:00
|
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
|
description = "Phabricator CLI from Mozilla to support submission of a series of commits";
|
|
|
|
|
longDescription = ''
|
|
|
|
|
moz-phab is a custom command-line tool, which communicates to
|
|
|
|
|
Phabricator’s API, providing several conveniences, including support for
|
|
|
|
|
submitting series of commits.
|
|
|
|
|
'';
|
|
|
|
|
homepage = "https://moz-conduit.readthedocs.io/en/latest/phabricator-user.html";
|
|
|
|
|
license = licenses.mpl20;
|
|
|
|
|
maintainers = [ maintainers.kvark ];
|
2021-11-19 17:25:50 +00:00
|
|
|
|
platforms = platforms.unix;
|
2021-11-17 17:30:53 +00:00
|
|
|
|
};
|
|
|
|
|
}
|