From 8d19fd63b0db2d43f99221cbbbdabf36c12e345e Mon Sep 17 00:00:00 2001 From: koralowiec <36413794+koralowiec@users.noreply.github.com> Date: Sun, 1 Oct 2023 14:31:50 +0200 Subject: [PATCH] kubectl-neat: init at 2.0.3 --- pkgs/by-name/ku/kubectl-neat/package.nix | 29 ++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 pkgs/by-name/ku/kubectl-neat/package.nix diff --git a/pkgs/by-name/ku/kubectl-neat/package.nix b/pkgs/by-name/ku/kubectl-neat/package.nix new file mode 100644 index 000000000000..c0ce31abb926 --- /dev/null +++ b/pkgs/by-name/ku/kubectl-neat/package.nix @@ -0,0 +1,29 @@ +{ lib, buildGoModule, fetchFromGitHub, bash }: + +buildGoModule rec { + pname = "kubectl-neat"; + version = "2.0.3"; + + src = fetchFromGitHub { + owner = "itaysk"; + repo = "kubectl-neat"; + rev = "v${version}"; + hash = "sha256-j8v0zJDBqHzmLamIZPW9UvMe9bv/m3JUQKY+wsgMTFk="; + }; + + vendorHash = "sha256-vGXoYR0DT9V1BD/FN/4szOal0clsLlqReTFkAd2beMw="; + + postBuild = '' + # Replace path to bash in a script + # Without this change, there's a problem when running tests + sed 's,#!/bin/bash,#!${bash}/bin/bash,' -i test/kubectl-stub + ''; + + meta = with lib; { + description = "Clean up Kubernetes yaml and json output to make it readable"; + homepage = "https://github.com/itaysk/kubectl-neat"; + changelog = "https://github.com/itaysk/kubectl-neat/releases/tag/v${version}"; + license = licenses.asl20; + maintainers = [ maintainers.koralowiec ]; + }; +}