19 inherit (lib) optionals;
21 stdenv.mkDerivation rec {
22 pname = "bucklespring";
25 src = fetchFromGitHub {
29 sha256 = "0prhqibivxzmz90k79zpwx3c97h8wa61rk5ihi9a5651mnc46mna";
42 ++ optionals (legacy) [
46 ++ optionals (!legacy) [ libinput ];
48 makeFlags = optionals (!legacy) [ "libinput=1" ];
53 mkdir -p $out/share/wav
54 cp -r $src/wav $out/share/.
55 install -D ./buckle.desktop $out/share/applications/buckle.desktop
56 install -D ./buckle $out/bin/buckle
57 wrapProgram $out/bin/buckle --add-flags "-p $out/share/wav"
63 description = "Nostalgia bucklespring keyboard sound";
64 mainProgram = "buckle";
66 When built with libinput (wayland or bare console),
67 users need to be in the input group to use this:
68 <code>users.users.alice.extraGroups = [ "input" ];</code>
70 homepage = "https://github.com/zevv/bucklespring";
71 license = licenses.gpl2Only;
72 platforms = platforms.unix;
73 maintainers = [ maintainers.evils ];