nixpkgs/pkgs/applications/misc/kupfer/default.nix
Profpatsch 4a7f99d55d treewide: with stdenv.lib; in meta -> with lib;
Part of: https://github.com/NixOS/nixpkgs/issues/108938

meta = with stdenv.lib;

is a widely used pattern. We want to slowly remove
the `stdenv.lib` indirection and encourage people
to use `lib` directly. Thus let’s start with the meta
field.

This used a rewriting script to mostly automatically
replace all occurances of this pattern, and add the
`lib` argument to the package header if it doesn’t
exist yet.

The script in its current form is available at
https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
2021-01-11 10:38:22 +01:00

55 lines
1.3 KiB
Nix

{ lib, stdenv
, fetchurl
, intltool
, python3Packages
, gobject-introspection
, gtk3
, libwnck3
, keybinder3
, wrapGAppsHook
, wafHook
}:
with python3Packages;
buildPythonApplication rec {
pname = "kupfer";
version = "319";
format = "other";
src = fetchurl {
url = "https://github.com/kupferlauncher/kupfer/releases/download/v${version}/kupfer-v${version}.tar.xz";
sha256 = "0c9xjx13r8ckfr4az116bhxsd3pk78v04c3lz6lqhraak0rp4d92";
};
nativeBuildInputs = [
wrapGAppsHook intltool
# For setup hook
gobject-introspection wafHook
];
buildInputs = [ docutils libwnck3 keybinder3 ];
propagatedBuildInputs = [ pygobject3 gtk3 pyxdg dbus-python pycairo ];
# without strictDeps kupfer fails to build: Could not find the python module 'gi.repository.Gtk'
# see https://github.com/NixOS/nixpkgs/issues/56943 for details
strictDeps = false;
postInstall = ''
gappsWrapperArgs+=(
"--prefix" "PYTHONPATH" : "${makePythonPath propagatedBuildInputs}"
"--set" "PYTHONNOUSERSITE" "1"
)
'';
doCheck = false; # no tests
meta = with lib; {
description = "A smart, quick launcher";
homepage = "https://kupferlauncher.github.io/";
license = licenses.gpl3;
maintainers = with maintainers; [ cobbal ];
platforms = platforms.linux;
};
}