about summary refs log tree commit diff
path: root/nixpkgs/pkgs/by-name/hy/hyprnome/package.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/by-name/hy/hyprnome/package.nix')
-rw-r--r--nixpkgs/pkgs/by-name/hy/hyprnome/package.nix43
1 files changed, 43 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/by-name/hy/hyprnome/package.nix b/nixpkgs/pkgs/by-name/hy/hyprnome/package.nix
new file mode 100644
index 000000000000..691ebc574a43
--- /dev/null
+++ b/nixpkgs/pkgs/by-name/hy/hyprnome/package.nix
@@ -0,0 +1,43 @@
+{
+  lib,
+  rustPlatform,
+  fetchFromGitHub,
+  installShellFiles,
+  nix-update-script,
+}:
+
+rustPlatform.buildRustPackage rec {
+  pname = "hyprnome";
+  version = "0.2.0";
+
+  src = fetchFromGitHub {
+    owner = "donovanglover";
+    repo = "hyprnome";
+    rev = version;
+    hash = "sha256-zlXiT2EOIdgIDI4NQuU3C903SSq5bylBAFJXyv7mdJ4=";
+  };
+
+  cargoHash = "sha256-DpbRs97sr5wpJSrYF99ZiQ0SZOZdoQjfaLhKIAU95HA=";
+
+  nativeBuildInputs = [ installShellFiles ];
+
+  postInstall = ''
+    installManPage target/man/hyprnome.1
+
+    installShellCompletion --cmd hyprnome \
+      --bash target/completions/hyprnome.bash \
+      --fish target/completions/hyprnome.fish \
+      --zsh target/completions/_hyprnome
+  '';
+
+  passthru.updateScript = nix-update-script { };
+
+  meta = with lib; {
+    description = "GNOME-like workspace switching in Hyprland";
+    homepage = "https://github.com/donovanglover/hyprnome";
+    license = licenses.gpl3Plus;
+    platforms = platforms.linux;
+    maintainers = with maintainers; [ donovanglover ];
+    mainProgram = "hyprnome";
+  };
+}