]> git.scottworley.com Git - nix-env-apps/blob - default.nix
nixpkgs 25.11 pyproject boilerplate
[nix-env-apps] / default.nix
1 { pkgs ? import <nixpkgs> { }, lint ? false }:
2 pkgs.python3Packages.callPackage ({ autopep8, buildPythonPackage
3 , gobject-introspection, gtk4, lib, makeDesktopItem, mypy, pylint, pygobject3
4 , setuptools, wrapGAppsHook4, }:
5 buildPythonPackage rec {
6 pname = "apps";
7 version = "1.0.2";
8
9 src = lib.cleanSource ./.;
10
11 pyproject = true;
12 build-system = [ setuptools ];
13
14 doCheck = true;
15 checkPhase = "./test.sh";
16
17 nativeBuildInputs = [ gobject-introspection wrapGAppsHook4 ];
18 nativeCheckInputs = [ mypy ] ++ lib.optionals lint [ autopep8 pylint ];
19 buildInputs = [ gtk4 ];
20 pythonPath = [ pygobject3 ];
21
22 postInstall = ''
23 cp -r $desktopItem/share $out
24 '';
25
26 desktopItem = makeDesktopItem {
27 name = "Apps";
28 exec = "apps";
29 icon = ./apps.png;
30 comment = "Configure nix-env Apps";
31 desktopName = "Apps";
32 genericName = "Configure Apps";
33 categories = [ "Settings" ];
34 };
35
36 meta = {
37 description =
38 "A simple GUI for managing declarative nix-env user environments";
39 homepage = "https://git.scottworley.com/nix-env-apps";
40 license = pkgs.lib.licenses.gpl3;
41 maintainers = with pkgs.lib.maintainers; [ chkno ];
42 };
43
44 }) { }