From 2d06eed03ccce14f242e2a5f5da7f77b2c830df2 Mon Sep 17 00:00:00 2001 From: eljamm Date: Fri, 2 Aug 2024 09:26:59 +0100 Subject: [PATCH 1/3] albert: remove `with lib;` in meta --- pkgs/applications/misc/albert/default.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/misc/albert/default.nix b/pkgs/applications/misc/albert/default.nix index 338f09ca8520..a3ddd48990ef 100644 --- a/pkgs/applications/misc/albert/default.nix +++ b/pkgs/applications/misc/albert/default.nix @@ -74,7 +74,7 @@ stdenv.mkDerivation (finalAttrs: { updateScript = nix-update-script { }; }; - meta = with lib; { + meta = { description = "Fast and flexible keyboard launcher"; longDescription = '' Albert is a desktop agnostic launcher. Its goals are usability and beauty, @@ -84,13 +84,13 @@ stdenv.mkDerivation (finalAttrs: { homepage = "https://albertlauncher.github.io"; changelog = "https://github.com/albertlauncher/albert/blob/${finalAttrs.src.rev}/CHANGELOG.md"; # See: https://github.com/NixOS/nixpkgs/issues/279226 - license = licenses.unfree; - maintainers = with maintainers; [ + license = lib.licenses.unfree; + maintainers = with lib.maintainers; [ ericsagnes synthetica eljamm ]; mainProgram = "albert"; - platforms = platforms.linux; + platforms = lib.platforms.linux; }; }) From 532ba73a97a88f0fcad8d86dc7fef9f50f9b4e33 Mon Sep 17 00:00:00 2001 From: eljamm Date: Fri, 2 Aug 2024 09:28:18 +0100 Subject: [PATCH 2/3] albert: use substituteInPlace instead of sed This is more robust and automatic to check if the file still exists in the same location and if we can still replace the string. --- pkgs/applications/misc/albert/default.nix | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/pkgs/applications/misc/albert/default.nix b/pkgs/applications/misc/albert/default.nix index a3ddd48990ef..b0c10117baa9 100644 --- a/pkgs/applications/misc/albert/default.nix +++ b/pkgs/applications/misc/albert/default.nix @@ -58,10 +58,8 @@ stdenv.mkDerivation (finalAttrs: { postPatch = '' find -type f -name CMakeLists.txt -exec sed -i {} -e '/INSTALL_RPATH/d' \; - # WARN: This is necessary for albert to detect the package libraries. - # Please check if the file below has changed upstream before updating. - sed -i src/app/qtpluginprovider.cpp \ - -e "/QStringList install_paths;/a install_paths << QFileInfo(\"$out/lib\").canonicalFilePath();" + substituteInPlace src/app/qtpluginprovider.cpp \ + --replace-fail "QStringList install_paths;" "QStringList install_paths;${"\n"}install_paths << QFileInfo(\"$out/lib\").canonicalFilePath();" ''; postFixup = '' From d563ec9a5d66c8bdf4979da30df577a61ef91d21 Mon Sep 17 00:00:00 2001 From: eljamm Date: Fri, 2 Aug 2024 09:57:08 +0100 Subject: [PATCH 3/3] albert: 0.24.3 -> 0.25.0 --- pkgs/applications/misc/albert/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/applications/misc/albert/default.nix b/pkgs/applications/misc/albert/default.nix index b0c10117baa9..ba33c8baa85b 100644 --- a/pkgs/applications/misc/albert/default.nix +++ b/pkgs/applications/misc/albert/default.nix @@ -21,13 +21,13 @@ stdenv.mkDerivation (finalAttrs: { pname = "albert"; - version = "0.24.3"; + version = "0.25.0"; src = fetchFromGitHub { owner = "albertlauncher"; repo = "albert"; rev = "v${finalAttrs.version}"; - hash = "sha256-9vR6G/9FSy1mqZCo19Mf0RuvW63DbnhEzp/h0p6eXqs="; + hash = "sha256-eowsQhaS9RGfsw157HahENuWUWtwkwyPNSFw135MW0c="; fetchSubmodules = true; };