Files
nixpkgs/pkgs/by-name/dp/dput-ng/package.nix
Dark Steveneq 646b892680
Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
push sheeet
2025-10-09 14:15:47 +02:00

66 lines
1.5 KiB
Nix

{
lib,
python3,
fetchFromGitLab,
nix-update-script,
}:
let
version = "1.43";
in
python3.pkgs.buildPythonApplication {
pname = "dput-ng";
inherit version;
pyproject = true;
src = fetchFromGitLab {
domain = "salsa.debian.org";
owner = "debian";
repo = "dput-ng";
tag = "debian/${version}";
hash = "sha256-zrH4h4C4y3oTiOXsidFv/rIJNzCdV2lqzNEg0SOkX4w=";
};
build-system = with python3.pkgs; [
setuptools
];
dependencies = with python3.pkgs; [
jsonschema
paramiko
sphinx
coverage
xdg
python-debian
];
postInstall = ''
cp -r bin $out/
'';
pythonImportsCheck = [ "dput" ];
nativeCheckInputs = with python3.pkgs; [
pytestCheckHook
];
# Requires running dpkg
disabledTestPaths = [ "tests/test_upload.py" ];
passthru.updateScript = nix-update-script {
# Debian's tagging scheme is the bane of my existence.
# Essentially: all tags from 1.40 onwards start with `debian/`,
# then the version, and then an optional suffix (usually reserved for backports).
# We want to ignore the backport versions, and strip the `debian/` prefix.
extraArgs = [ "--version-regex=(?:debian\/)?(\d+(?:\.\d+)*)(?:[_\+].*)?" ];
};
meta = {
description = "Next-generation Debian package upload tool";
homepage = "https://dput.readthedocs.io/en/latest/";
license = with lib.licenses; [ gpl2Plus ];
platforms = lib.platforms.linux;
maintainers = with lib.maintainers; [ pluiedev ];
mainProgram = "dput";
};
}