about summary refs log tree commit diff
path: root/pkgs/by-name/ve/ventoy/package.nix
diff options
context:
space:
mode:
authorAnderson Torres <torres.anderson.85@protonmail.com>2024-01-24 10:27:33 -0300
committerAnderson Torres <torres.anderson.85@protonmail.com>2024-01-24 10:27:33 -0300
commitcbe2b770fc8eeca5fb1440f6f4c5a13e63f743b9 (patch)
tree6af08bc59b170dbf09063f3a47b92f145a94e81f /pkgs/by-name/ve/ventoy/package.nix
parentb33805a0ecfd7dd99e251df95b720d2cc770cb87 (diff)
ventoy: 1.0.96 -> 1.0.97
Diffstat (limited to 'pkgs/by-name/ve/ventoy/package.nix')
-rw-r--r--pkgs/by-name/ve/ventoy/package.nix41
1 files changed, 20 insertions, 21 deletions
diff --git a/pkgs/by-name/ve/ventoy/package.nix b/pkgs/by-name/ve/ventoy/package.nix
index f7b90e6e252d3..4338932481ee7 100644
--- a/pkgs/by-name/ve/ventoy/package.nix
+++ b/pkgs/by-name/ve/ventoy/package.nix
@@ -1,6 +1,4 @@
 { lib
-, stdenv
-, fetchurl
 , autoPatchelfHook
 , bash
 , copyDesktopItems
@@ -9,6 +7,7 @@
 , dosfstools
 , e2fsprogs
 , exfat
+, fetchurl
 , gawk
 , gnugrep
 , gnused
@@ -19,6 +18,7 @@
 , ntfs3g
 , parted
 , procps
+, stdenv
 , util-linux
 , which
 , xfsprogs
@@ -38,7 +38,7 @@ assert defaultGuiType == "gtk3" -> withGtk3;
 assert defaultGuiType == "qt5" -> withQt5;
 
 let
-  inherit (lib) optional optionalString;
+  inherit (lib) optionals optionalString;
   inherit (libsForQt5) qtbase wrapQtAppsHook;
   arch = {
     x86_64-linux = "x86_64";
@@ -46,20 +46,16 @@ let
     aarch64-linux = "aarch64";
     mipsel-linux = "mips64el";
   }.${stdenv.hostPlatform.system}
-    or (throw "Unsupported platform ${stdenv.hostPlatform.system}");
+    or (throw "Unsupported platform: ${stdenv.hostPlatform.system}");
 in
 stdenv.mkDerivation (finalAttrs: {
   pname = "ventoy";
-  version = "1.0.96";
+  version = "1.0.97";
 
-  src =
-    let
-      inherit (finalAttrs) version;
-    in
-    fetchurl {
-      url = "https://github.com/ventoy/Ventoy/releases/download/v${version}/ventoy-${version}-linux.tar.gz";
-      hash = "sha256-eUpxfJQ0u3bpAXTUCKlMO/ViwKcBI59YFKJ3xGzSdcg=";
-    };
+  src = fetchurl {
+    url = "https://github.com/ventoy/Ventoy/releases/download/v${finalAttrs.version}/ventoy-${finalAttrs.version}-linux.tar.gz";
+    hash = "sha256-E2ipCCydsllY5UB+9JhDItkNO7AJBTN9S9QWeOBsEVA=";
+  };
 
   patches = [
     ./000-nixos-sanitization.patch
@@ -78,8 +74,8 @@ stdenv.mkDerivation (finalAttrs: {
     autoPatchelfHook
     makeWrapper
   ]
-  ++ optional (withQt5 || withGtk3) copyDesktopItems
-  ++ optional withQt5 wrapQtAppsHook;
+  ++ optionals (withQt5 || withGtk3) [ copyDesktopItems ]
+  ++ optionals withQt5 [ wrapQtAppsHook ];
 
   buildInputs = [
     bash
@@ -96,12 +92,14 @@ stdenv.mkDerivation (finalAttrs: {
     which
     xz
   ]
-  ++ optional withCryptsetup cryptsetup
-  ++ optional withExt4 e2fsprogs
-  ++ optional withGtk3 gtk3
-  ++ optional withNtfs ntfs3g
-  ++ optional withXfs xfsprogs
-  ++ optional withQt5 qtbase;
+  ++ optionals withCryptsetup [ cryptsetup ]
+  ++ optionals withExt4 [ e2fsprogs ]
+  ++ optionals withGtk3 [ gtk3 ]
+  ++ optionals withNtfs [ ntfs3g ]
+  ++ optionals withXfs [ xfsprogs ]
+  ++ optionals withQt5 [ qtbase ];
+
+  strictDeps = true;
 
   desktopItems = [
     (makeDesktopItem {
@@ -203,6 +201,7 @@ stdenv.mkDerivation (finalAttrs: {
     '';
     changelog = "https://www.ventoy.net/doc_news.html";
     license = lib.licenses.gpl3Plus;
+    mainProgram = "ventoy";
     maintainers = with lib.maintainers; [ AndersonTorres ];
     platforms = [ "x86_64-linux" "i686-linux" "aarch64-linux" "mipsel-linux" ];
     sourceProvenance = with lib.sourceTypes; [ binaryNativeCode ];