nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 flit-scm,
6 packaging,
7 setuptools-scm,
8 pytestCheckHook,
9}:
10
11buildPythonPackage rec {
12 pname = "nipreps-versions";
13 version = "1.0.4";
14 pyproject = true;
15
16 src = fetchFromGitHub {
17 owner = "nipreps";
18 repo = "version-schemes";
19 tag = version;
20 hash = "sha256-B2wtLurzgk59kTooH51a2dewK7aEyA0dAm64Wp+tqhM=";
21 };
22
23 env.SETUPTOOLS_SCM_PRETEND_VERSION = version;
24
25 nativeBuildInputs = [
26 flit-scm
27 setuptools-scm
28 ];
29
30 propagatedBuildInputs = [ packaging ];
31
32 nativeCheckInputs = [ pytestCheckHook ];
33 pythonImportsCheck = [ "nipreps_versions" ];
34
35 meta = {
36 description = "Setuptools_scm plugin for nipreps version schemes";
37 homepage = "https://github.com/nipreps/version-schemes";
38 changelog = "https://github.com/nipreps/version-schemes/blob/${src.rev}/CHANGES.md";
39 license = lib.licenses.asl20;
40 maintainers = with lib.maintainers; [ bcdarwin ];
41 };
42}