From 68f712504663bddfbcaebacedb96caf9ca1f7cb7 Mon Sep 17 00:00:00 2001 From: Isuldor Date: Sat, 27 Jun 2026 15:23:21 -0700 Subject: [PATCH] Enhance desktop shortcut --- docs/eqlegends.md | 17 +++++++++++++++++ packages/eqlegends/package.nix | 17 ++++++++++++++++- 2 files changed, 33 insertions(+), 1 deletion(-) diff --git a/docs/eqlegends.md b/docs/eqlegends.md index 9e4e0b9..f40fc19 100644 --- a/docs/eqlegends.md +++ b/docs/eqlegends.md @@ -12,6 +12,8 @@ Run: nix run .#eqlegends ``` +If the package is installed into a NixOS or Home Manager profile, it also provides a desktop entry named **EverQuest Legends** for KDE Plasma and other freedesktop launchers. + The flake fetches the installer from: ```text @@ -61,6 +63,21 @@ If the flake app is installed into a profile, the helper is available as: eqlegends-reset-prefix ``` +## Desktop Entry + +The package installs: + +```text +share/applications/eqlegends.desktop +share/icons/hicolor/256x256/apps/eqlegends.png +``` + +After your NixOS/Home Manager activation includes the package, KDE Plasma should show **EverQuest Legends** in the application launcher under games. If Plasma does not notice it immediately, log out and back in, or refresh the application database: + +```bash +kbuildsycoca6 +``` + ## DXVK The wrapper defaults to WineD3D. Run with DXVK only if the game client needs it or performs better with Vulkan translation: diff --git a/packages/eqlegends/package.nix b/packages/eqlegends/package.nix index 43d767c..9ffbce8 100644 --- a/packages/eqlegends/package.nix +++ b/packages/eqlegends/package.nix @@ -3,6 +3,8 @@ , runCommand , writeShellScriptBin , makeDesktopItem +, imagemagick +, p7zip , wineWow64Packages , dxvk , symlinkJoin @@ -22,6 +24,14 @@ let hash = "sha256-MFuIuPt/MlVzlCwiIGjjKkYT0Sm7ov5wm5Mrd1zfzx4="; }; + iconFiles = runCommand "eqlegends-icon" { nativeBuildInputs = [ imagemagick p7zip ]; } '' + mkdir -p $out/share/icons/hicolor/256x256/apps + + tmpdir="$(mktemp -d)" + 7z e -y -o"$tmpdir" ${installer} LaunchPad.ico >/dev/null + magick "$tmpdir/LaunchPad.ico[0]" "$out/share/icons/hicolor/256x256/apps/eqlegends.png" + ''; + setupDxvk = writeShellScriptBin "eqlegends-setup-dxvk" '' set -euo pipefail @@ -143,8 +153,12 @@ EOF name = "eqlegends"; desktopName = "EverQuest Legends"; comment = "EverQuest Legends LaunchPad (Wine)"; + icon = "eqlegends"; exec = "eqlegends"; - categories = [ "Game" ]; + terminal = false; + categories = [ "Game" "RolePlaying" ]; + keywords = [ "EverQuest" "EverQuest Legends" "Daybreak" "Game" ]; + startupNotify = true; }; desktopFiles = runCommand "eqlegends-desktop" { } '' @@ -158,6 +172,7 @@ symlinkJoin { paths = [ launcher reset + iconFiles desktopFiles ];