diff --git a/pkgs/by-name/ij/ijq/package.nix b/pkgs/by-name/ij/ijq/package.nix new file mode 100644 index 0000000000000..69514ad3c648f --- /dev/null +++ b/pkgs/by-name/ij/ijq/package.nix @@ -0,0 +1,57 @@ +{ + buildGoModule, + fetchFromSourcehut, + lib, + jq, + installShellFiles, + makeBinaryWrapper, + scdoc, +}: + +buildGoModule rec { + pname = "ijq"; + version = "1.1.1"; + + src = fetchFromSourcehut { + owner = "~gpanders"; + repo = "ijq"; + rev = "v${version}"; + hash = "sha256-rnSpXMadZW6I+7tIYqr1Cb4z00gdREsqin/r6OXaDMA="; + }; + + vendorHash = "sha256-zRa8MPWFvcoVm+LstbSAl1VY3oWMujZPjWS/ti1VXjE="; + + nativeBuildInputs = [ + installShellFiles + makeBinaryWrapper + scdoc + ]; + + ldflags = [ + "-s" + "-w" + "-X main.Version=${version}" + ]; + + postBuild = '' + scdoc < ijq.1.scd > ijq.1 + installManPage ijq.1 + ''; + + postInstall = '' + wrapProgram "$out/bin/ijq" \ + --prefix PATH : "${lib.makeBinPath [ jq ]}" + ''; + + meta = with lib; { + description = "Interactive wrapper for jq"; + mainProgram = "ijq"; + homepage = "https://git.sr.ht/~gpanders/ijq"; + license = licenses.gpl3Plus; + maintainers = with maintainers; [ + justinas + mattpolzin + SuperSandro2000 + ]; + }; +} diff --git a/pkgs/development/tools/ijq/default.nix b/pkgs/development/tools/ijq/default.nix deleted file mode 100644 index bdca841eeccb0..0000000000000 --- a/pkgs/development/tools/ijq/default.nix +++ /dev/null @@ -1,37 +0,0 @@ -{ buildGoModule, fetchFromSourcehut, lib, jq, installShellFiles, makeWrapper, scdoc }: - -buildGoModule rec { - pname = "ijq"; - version = "1.1.0"; - - src = fetchFromSourcehut { - owner = "~gpanders"; - repo = pname; - rev = "v${version}"; - sha256 = "sha256-KtWJwIofMKW+03DFY4UWf3ni1DKuH289svh8iOPo1so="; - }; - - vendorHash = "sha256-oMkL4qZUS47h9izDad7Ar0Npd6toIZQuy1YIdEoJ2AM="; - - nativeBuildInputs = [ installShellFiles makeWrapper scdoc ]; - - ldflags = [ "-s" "-w" "-X main.Version=${version}" ]; - - postBuild = '' - scdoc < ijq.1.scd > ijq.1 - installManPage ijq.1 - ''; - - postInstall = '' - wrapProgram "$out/bin/ijq" \ - --prefix PATH : "${lib.makeBinPath [ jq ]}" - ''; - - meta = with lib; { - description = "Interactive wrapper for jq"; - mainProgram = "ijq"; - homepage = "https://git.sr.ht/~gpanders/ijq"; - license = licenses.gpl3Plus; - maintainers = with maintainers; [ justinas SuperSandro2000 ]; - }; -} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 6f22aaf47e6fc..e7f422ecc77ac 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -8932,8 +8932,6 @@ with pkgs; packages = config.ihaskell.packages or (_: []); }; - ijq = callPackage ../development/tools/ijq { }; - iruby = callPackage ../applications/editors/jupyter-kernels/iruby { }; ike-scan = callPackage ../tools/security/ike-scan { };