about summary refs log tree commit diff
path: root/pkgs/by-name/gh
diff options
context:
space:
mode:
authorLoïc Reynier <loic@loicreynier.fr>2024-04-02 14:02:54 +0000
committerLoïc Reynier <loic@loicreynier.fr>2024-04-02 14:02:54 +0000
commitb4f96d2b981a92a2d2699842adcfa9e758cad12e (patch)
tree881ad2cb78319759ab43244bfee5c7f0c0b0e267 /pkgs/by-name/gh
parent9806daf34c54f3d9cbdac6881be3068c8ef634da (diff)
gh-f: init at 1.1.5
Co-authored-by: Aleksana <alexander.huang.y@gmail.com>
Diffstat (limited to 'pkgs/by-name/gh')
-rw-r--r--pkgs/by-name/gh/gh-f/package.nix41
1 files changed, 41 insertions, 0 deletions
diff --git a/pkgs/by-name/gh/gh-f/package.nix b/pkgs/by-name/gh/gh-f/package.nix
new file mode 100644
index 0000000000000..8fb4fa57d9b99
--- /dev/null
+++ b/pkgs/by-name/gh/gh-f/package.nix
@@ -0,0 +1,41 @@
+{ lib
+, fetchFromGitHub
+, stdenvNoCC
+, makeWrapper
+, fzf
+, coreutils
+, bat
+}:
+
+stdenvNoCC.mkDerivation rec {
+  pname = "gh-f";
+  version = "1.1.5";
+
+  src = fetchFromGitHub {
+    owner = "gennaro-tedesco";
+    repo = "gh-f";
+    rev = "v${version}";
+    hash = "sha256-ITl8T8Oe21m047ygFlxWVjzUYPG4rlcTjfSpsropYJw=";
+  };
+
+  nativeBuildInputs = [
+    makeWrapper
+  ];
+
+  installPhase = ''
+    install -D -m755 "gh-f" "$out/bin/gh-f"
+  '';
+
+  postFixup = ''
+    wrapProgram "$out/bin/gh-f" --prefix PATH : "${lib.makeBinPath [fzf bat coreutils]}"
+  '';
+
+  meta = with lib; {
+    homepage = "https://github.com/gennaro-tedesco/gh-f";
+    description = "GitHub CLI ultimate FZF extension";
+    maintainers = with maintainers; [ loicreynier ];
+    license = licenses.unlicense;
+    mainProgram = "gh-f";
+    platforms = platforms.all;
+  };
+}