leo-editor: cleanup

+13 -8
+13 -8
pkgs/by-name/le/leo-editor/package.nix
··· 8 8 libsForQt5, 9 9 }: 10 10 11 - stdenv.mkDerivation rec { 11 + stdenv.mkDerivation (finalAttrs: { 12 12 pname = "leo-editor"; 13 13 version = "6.8.6.1"; 14 14 15 15 src = fetchFromGitHub { 16 16 owner = "leo-editor"; 17 17 repo = "leo-editor"; 18 - rev = version; 19 - sha256 = "sha256-3ojiIjsGJpPgVSUi0QhIddqwsDxfRWxhxAQ5YmzwZiQ="; 18 + tag = "v${finalAttrs.version}"; 19 + hash = "sha256-3ojiIjsGJpPgVSUi0QhIddqwsDxfRWxhxAQ5YmzwZiQ="; 20 20 }; 21 21 22 22 dontBuild = true; ··· 26 26 makeWrapper 27 27 python3 28 28 ]; 29 + 29 30 propagatedBuildInputs = with python3.pkgs; [ 30 31 pyqt6 31 32 docutils ··· 36 37 exec = "leo %U"; 37 38 icon = "leoapp32"; 38 39 type = "Application"; 39 - comment = meta.description; 40 + comment = finalAttrs.meta.description; 40 41 desktopName = "Leo"; 41 42 genericName = "Text Editor"; 42 43 categories = [ ··· 82 83 }; 83 84 84 85 installPhase = '' 86 + runHook preInstall 87 + 85 88 mkdir -p "$out/share/icons/hicolor/32x32/apps" 86 89 cp leo/Icons/leoapp32.png "$out/share/icons/hicolor/32x32/apps" 87 90 ··· 96 99 --add-flags "-O $out/share/leo-editor/launchLeo.py" 97 100 98 101 wrapQtApp $out/bin/leo 102 + 103 + runHook postInstall 99 104 ''; 100 105 101 - meta = with lib; { 106 + meta = { 102 107 homepage = "https://leo-editor.github.io/leo-editor/"; 103 108 description = "Powerful folding editor"; 104 109 longDescription = "Leo is a PIM, IDE and outliner that accelerates the work flow of programmers, authors and web designers."; 105 - license = licenses.mit; 106 - maintainers = with maintainers; [ 110 + license = lib.licenses.mit; 111 + maintainers = with lib.maintainers; [ 107 112 leonardoce 108 113 kashw2 109 114 ]; 110 115 mainProgram = "leo"; 111 116 }; 112 - } 117 + })