pytrainer: unpin python 3.10
[NixPkgs.git] / pkgs / desktops / expidus / file-manager / default.nix
blob8de6262d86baed8b08e7348536447a06c11972e6
1 { lib, flutter, fetchFromGitHub }:
2 flutter.buildFlutterApplication rec {
3   pname = "expidus-file-manager";
4   version = "0.2.1";
6   src = fetchFromGitHub {
7     owner = "ExpidusOS";
8     repo = "file-manager";
9     rev = version;
10     hash = "sha256-R6eszy4Dz8tAPRTwZzRiZWIgVMiGv5zlhFB/HcD6gqg=";
11   };
13   flutterBuildFlags = [
14     "--dart-define=COMMIT_HASH=b4181b9cff18a07e958c81d8f41840d2d36a6705"
15   ];
17   pubspecLock = lib.importJSON ./pubspec.lock.json;
19   gitHashes = {
20     libtokyo = "sha256-T0+vyfSfijLv7MvM+zt3bkVpb3aVrlDnse2xyNMp9GU=";
21     libtokyo_flutter = "sha256-T0+vyfSfijLv7MvM+zt3bkVpb3aVrlDnse2xyNMp9GU=";
22   };
24   postInstall = ''
25     rm $out/bin/file_manager
26     ln -s $out/app/$pname/file_manager $out/bin/expidus-file-manager
28     mkdir -p $out/share/applications
29     mv $out/app/$pname/data/com.expidusos.file_manager.desktop $out/share/applications
31     mkdir -p $out/share/icons
32     mv $out/app/$pname/data/com.expidusos.file_manager.png $out/share/icons
34     mkdir -p $out/share/metainfo
35     mv $out/app/$pname/data/com.expidusos.file_manager.metainfo.xml $out/share/metainfo
37     substituteInPlace "$out/share/applications/com.expidusos.file_manager.desktop" \
38       --replace "Exec=file_manager" "Exec=$out/bin/expidus-file-manager" \
39       --replace "Icon=com.expidusos.file_manager" "Icon=$out/share/icons/com.expidusos.file_manager.png"
40   '';
42   meta = with lib; {
43     description = "ExpidusOS File Manager";
44     homepage = "https://expidusos.com";
45     license = licenses.gpl3;
46     maintainers = with maintainers; [ RossComputerGuy ];
47     platforms = [ "x86_64-linux" "aarch64-linux" ];
48     mainProgram = "expidus-file-manager";
49   };