summary refs log tree commit diff
diff options
context:
space:
mode:
authorSandro <sandro.jaeckel@gmail.com>2021-07-22 09:45:48 +0200
committerGitHub <noreply@github.com>2021-07-22 09:45:48 +0200
commit6337261453766419e8369a93923dbce0d41ebd22 (patch)
tree8738a272ec546fc8c23a8f10d9714cc7d5eca254
parentfb7b11e5452f57cd9fa74e0225668af740e05f50 (diff)
parent4ac8c881c37875f4e5099b1a65fef03c2e0b9389 (diff)
downloadnixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar.gz
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar.bz2
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar.lz
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar.xz
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.tar.zst
nixpkgs-6337261453766419e8369a93923dbce0d41ebd22.zip
Merge pull request #130588 from hqurve/krunner-symbols
-rw-r--r--maintainers/maintainer-list.nix6
-rw-r--r--pkgs/desktops/plasma-5/3rdparty/addons/krunner-symbols.nix40
-rw-r--r--pkgs/desktops/plasma-5/default.nix1
-rw-r--r--pkgs/top-level/aliases.nix1
4 files changed, 48 insertions, 0 deletions
diff --git a/maintainers/maintainer-list.nix b/maintainers/maintainer-list.nix
index f6d07ac77a8..e534c0ddff7 100644
--- a/maintainers/maintainer-list.nix
+++ b/maintainers/maintainer-list.nix
@@ -4355,6 +4355,12 @@
     github = "HolgerPeters";
     githubId = 4097049;
   };
+  hqurve = {
+    email = "hqurve@outlook.com";
+    github = "hqurve";
+    githubId = 53281855;
+    name = "hqurve";
+  };
   hrdinka = {
     email = "c.nix@hrdinka.at";
     github = "hrdinka";
diff --git a/pkgs/desktops/plasma-5/3rdparty/addons/krunner-symbols.nix b/pkgs/desktops/plasma-5/3rdparty/addons/krunner-symbols.nix
new file mode 100644
index 00000000000..7a0b6162257
--- /dev/null
+++ b/pkgs/desktops/plasma-5/3rdparty/addons/krunner-symbols.nix
@@ -0,0 +1,40 @@
+{ lib, stdenv
+, cmake, fetchFromGitHub, extra-cmake-modules
+, qtbase, wrapQtAppsHook, ki18n, kdelibs4support, krunner
+}:
+
+stdenv.mkDerivation rec {
+  pname = "krunner-symbols";
+  version = "1.1.0";
+
+  src = fetchFromGitHub {
+    owner = "domschrei";
+    repo = "krunner-symbols";
+    rev = version;
+    sha256 = "sha256-YsoZdPTWpk3/YERwerrVEcaf2IfGVJwpq32onhP8Exo=";
+  };
+
+  buildInputs = [ qtbase ki18n kdelibs4support krunner ];
+  nativeBuildInputs = [ cmake wrapQtAppsHook extra-cmake-modules ];
+
+  postPatch = ''
+    # symbols.cpp hardcodes the location of configuration files
+    substituteInPlace symbols.cpp \
+      --replace "/usr/share/config/krunner-symbol" "$out/share/config/krunner-symbol"
+
+    # change cmake flag names to output using the correct qt-plugin prefix and kservice location
+    substituteInPlace CMakeLists.txt \
+      --replace "LOCATION_PLUGIN" "KDE_INSTALL_PLUGINDIR" \
+      --replace "LOCATION_DESKTOP" "KDE_INSTALL_KSERVICES5DIR"
+  '';
+
+  cmakeFlags = [ "-DLOCATION_CONFIG=share/config" ];
+
+  meta = with lib; {
+    description = "A little krunner plugin (Plasma 5) to retrieve unicode symbols, or any other string, based on a corresponding keyword";
+    homepage = "https://github.com/domschrei/krunner-symbols";
+    license = licenses.gpl3Only;
+    maintainers = with maintainers; [ hqurve ];
+    platforms = platforms.linux;
+  };
+}
diff --git a/pkgs/desktops/plasma-5/default.nix b/pkgs/desktops/plasma-5/default.nix
index 4b41e5ad9d5..9252aa7b39b 100644
--- a/pkgs/desktops/plasma-5/default.nix
+++ b/pkgs/desktops/plasma-5/default.nix
@@ -158,6 +158,7 @@ let
         kwin-dynamic-workspaces = callPackage ./3rdparty/kwin/scripts/dynamic-workspaces.nix { };
         kwin-tiling = callPackage ./3rdparty/kwin/scripts/tiling.nix { };
         krohnkite = callPackage ./3rdparty/kwin/scripts/krohnkite.nix { };
+        krunner-symbols = callPackage ./3rdparty/addons/krunner-symbols.nix { };
         parachute = callPackage ./3rdparty/kwin/scripts/parachute.nix { };
       };
 
diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix
index eeb6df85462..f5cd18c1fbb 100644
--- a/pkgs/top-level/aliases.nix
+++ b/pkgs/top-level/aliases.nix
@@ -1135,6 +1135,7 @@ mapAliases ({
     kwin-dynamic-workspaces
     kwin-tiling
     krohnkite
+    krunner-symbols
   ;
   inherit (libsForQt5)
     sddm