summaryrefslogtreecommitdiffstats
path: root/pkgs/by-name/wp/wpgtk/package.nix
blob: 28370985c4352889f6e63c488e31253c750c48bb (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
{
  lib,
  python3Packages,
  fetchFromGitHub,
  libxslt,
  gobject-introspection,
  gtk3,
  wrapGAppsHook3,
  adwaita-icon-theme,
  writableTmpDirAsHomeHook,
}:

python3Packages.buildPythonApplication (finalAttrs: {
  pname = "wpgtk";
  version = "6.7.1";
  pyproject = true;

  src = fetchFromGitHub {
    owner = "deviantfero";
    repo = "wpgtk";
    tag = finalAttrs.version;
    hash = "sha256-TbykgmS/F/6N7ZmcKlX79RhMvOMBsfFNl8TZKLji80w=";
  };

  build-system = with python3Packages; [ setuptools ];

  nativeBuildInputs = [
    gobject-introspection
    wrapGAppsHook3
    writableTmpDirAsHomeHook # The $HOME variable must be set to build the package. A "permission denied" error will occur otherwise
  ];

  buildInputs = [
    gtk3
    adwaita-icon-theme
    libxslt
  ];

  dependencies = with python3Packages; [
    pygobject3
    pillow
    pywal16
  ];

  # use pywal16 fork instead
  pythonRemoveDeps = [ "pywal" ];

  dontWrapGApps = true;

  makeWrapperArgs = [ "\${gappsWrapperArgs[@]}" ];

  # No test exist
  doCheck = false;

  meta = {
    description = "Template based wallpaper/colorscheme generator and manager";
    longDescription = ''
      In short, wpgtk is a colorscheme/wallpaper manager with a template system attached which lets you create templates from any textfile and will replace keywords on it on the fly, allowing for great styling and theming possibilities.

      wpgtk uses pywal16 as its colorscheme generator, but builds upon it with a UI and other features, such as the ability to mix and edit the colorschemes generated and save them with their respective wallpapers, having light and dark themes, hackable and fast GTK theme made specifically for wpgtk and custom keywords and values to replace in templates.

      INFO: To work properly, this tool needs "programs.dconf.enable = true" on nixos or dconf installed. A reboot may be required after installing dconf.
    '';
    homepage = "https://github.com/deviantfero/wpgtk";
    license = lib.licenses.gpl2Only;
    platforms = lib.platforms.linux;
    maintainers = with lib.maintainers; [
      melkor333
      cafkafk
    ];
    mainProgram = "wpg";
  };
})