1{ lib
2, fetchFromGitHub
3, python3
4}:
5
6python3.pkgs.buildPythonApplication rec {
7 pname = "circup";
8 version = "1.2.1";
9 format = "setuptools";
10
11 src = fetchFromGitHub {
12 owner = "adafruit";
13 repo = pname;
14 rev = "refs/tags/${version}";
15 hash = "sha256-a1s5a1AhZZ06lBvFjm5E0IuWXE4flLvwVjDgViXI62c=";
16 };
17
18 SETUPTOOLS_SCM_PRETEND_VERSION = version;
19
20 pythonRelaxDeps = [
21 "semver"
22 ];
23
24 nativeBuildInputs = with python3.pkgs; [
25 setuptools-scm
26 pythonRelaxDepsHook
27 ];
28
29 propagatedBuildInputs = with python3.pkgs; [
30 appdirs
31 click
32 findimports
33 requests
34 semver
35 setuptools
36 update_checker
37 ];
38
39 nativeCheckInputs = with python3.pkgs; [
40 pytestCheckHook
41 ];
42
43 postBuild = ''
44 export HOME=$(mktemp -d);
45 '';
46
47 pythonImportsCheck = [
48 "circup"
49 ];
50
51 meta = with lib; {
52 description = "CircuitPython library updater";
53 homepage = "https://github.com/adafruit/circup";
54 changelog = "https://github.com/adafruit/circup/releases/tag/${version}";
55 license = with licenses; [ mit ];
56 maintainers = with maintainers; [ fab ];
57 };
58}