1 { pkgs ? import <nixpkgs> { }, lint ? false }:
2 pkgs.python3Packages.callPackage ({ autopep8, buildPythonPackage, ffmpeg-full
3 , gobject-introspection, gtk4, lib, makeDesktopItem, makeWrapper, mypy, pylint
4 , pygobject3, wrapGAppsHook4, }:
5 buildPythonPackage rec {
9 src = lib.cleanSource ./.;
12 checkPhase = "./test.sh";
14 nativeBuildInputs = [ gobject-introspection makeWrapper wrapGAppsHook4 ];
15 nativeCheckInputs = [ mypy ] ++ lib.optionals lint [ autopep8 pylint ];
16 buildInputs = [ gtk4 ];
17 pythonPath = [ pygobject3 ];
20 wrapProgram "$out/bin/srec" --prefix PATH : ${ffmpeg-full}/bin
22 install -D ${./srec48.png} $out/share/icons/hicolor/48x48/apps/srec.png
23 install -D ${./srec.png} $out/share/icons/hicolor/256x256/apps/srec.png
24 install -D ${./srec.svg} $out/share/icons/hicolor/scalable/apps/srec.svg
26 cp -r $desktopItem/share/* $out/share
29 desktopItem = makeDesktopItem {
33 comment = "Record video and audio";
35 genericName = "Record Screen";
36 categories = [ "AudioVideo" "Video" ];
40 description = "A simple GUI for screen recording";
41 homepage = "https://git.scottworley.com/srec";
42 license = pkgs.lib.licenses.gpl3;
43 maintainers = with pkgs.lib.maintainers; [ chkno ];