Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at devShellTools-shell 75 lines 1.4 kB view raw
1{ 2 lib, 3 fetchFromGitHub, 4 dooit, 5 python3, 6 testers, 7 nix-update-script, 8 extraPackages ? [ ], 9}: 10python3.pkgs.buildPythonApplication rec { 11 pname = "dooit"; 12 version = "3.2.3"; 13 pyproject = true; 14 15 src = fetchFromGitHub { 16 owner = "dooit-org"; 17 repo = "dooit"; 18 tag = "v${version}"; 19 hash = "sha256-bI9X+2tTLnQwxfsnBmy2vBI3lJ4UX418zOy3oniVKWc="; 20 }; 21 22 build-system = with python3.pkgs; [ poetry-core ]; 23 24 pythonRelaxDeps = [ 25 "tzlocal" 26 "textual" 27 "sqlalchemy" 28 ]; 29 30 propagatedBuildInputs = 31 with python3.pkgs; 32 [ 33 pyperclip 34 textual 35 pyyaml 36 python-dateutil 37 sqlalchemy 38 platformdirs 39 tzlocal 40 click 41 ] 42 ++ extraPackages; 43 44 # /homeless-shelter 45 preBuild = '' 46 export HOME=$(mktemp -d) 47 ''; 48 49 checkInputs = with python3.pkgs; [ 50 pytestCheckHook 51 faker 52 ]; 53 54 passthru = { 55 tests.version = testers.testVersion { 56 package = dooit; 57 command = "HOME=$(mktemp -d) dooit --version"; 58 }; 59 60 updateScript = nix-update-script { }; 61 }; 62 63 meta = { 64 description = "TUI todo manager"; 65 homepage = "https://github.com/dooit-org/dooit"; 66 changelog = "https://github.com/dooit-org/dooit/blob/v${version}/CHANGELOG.md"; 67 license = lib.licenses.mit; 68 maintainers = with lib.maintainers; [ 69 khaneliman 70 wesleyjrz 71 kraanzu 72 ]; 73 mainProgram = "dooit"; 74 }; 75}