Skip to content

Commit

Permalink
Merge pull request #155076 from cameronfyfe/add-ets
Browse files Browse the repository at this point in the history
ets: init at 0.2.1
  • Loading branch information
legendofmiracles authored May 16, 2022
2 parents fef077c + 8d2537a commit dd9dc13
Show file tree
Hide file tree
Showing 3 changed files with 50 additions and 0 deletions.
6 changes: 6 additions & 0 deletions maintainers/maintainer-list.nix
Original file line number Diff line number Diff line change
Expand Up @@ -1953,6 +1953,12 @@
githubId = 7435854;
name = "Victor Calvert";
};
cameronfyfe = {
email = "[email protected]";
github = "cameronfyfe";
githubId = 21013281;
name = "Cameron Fyfe";
};
cameronnemo = {
email = "[email protected]";
github = "cameronnemo";
Expand Down
42 changes: 42 additions & 0 deletions pkgs/tools/misc/ets/default.nix
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{ lib, buildGoModule, fetchFromGitHub, fetchpatch, installShellFiles }:

buildGoModule rec {
pname = "ets";
version = "0.2.1";

src = fetchFromGitHub {
owner = "zmwangx";
repo = pname;
rev = "v${version}";
sha256 = "sha256-XWIDo5msTMTLr60x1R9cwsiZIDG6G+uHWx8idt4F2iA=";
};

# https://github.com/zmwangx/ets/pull/18/
patches = [ (fetchpatch {
url = "https://github.com/zmwangx/ets/commit/600ec17a9c86ca63cd022d00439cdc4978e2afa9.patch";
sha256 = "sha256-SGCISHkWNFubgKkQYx8Vf5/fknNDfPNYkSuw1mMhZaE=";
}) ];

vendorSha256 = "sha256-+8dXfqOu8XTw2uEx3GAynQSHtzifejZtddr1CdxrupA=";

ldflags = [ "-s" "-w" "-X main.version=v${version}-nixpkgs" ];

nativeBuildInputs = [ installShellFiles ];

preBuild = ''
rm -rf fixtures
'';

postInstall = ''
installManPage ets.1
'';

doCheck = false;

meta = with lib; {
description = "Command output timestamper";
homepage = "https://github.com/zmwangx/ets/";
license = licenses.mit;
maintainers = with maintainers; [ cameronfyfe ];
};
}
2 changes: 2 additions & 0 deletions pkgs/top-level/all-packages.nix
Original file line number Diff line number Diff line change
Expand Up @@ -5644,6 +5644,8 @@ with pkgs;

ethtool = callPackage ../tools/misc/ethtool { };

ets = callPackage ../tools/misc/ets { };

ettercap = callPackage ../applications/networking/sniffers/ettercap { };

eventstat = callPackage ../os-specific/linux/eventstat { };
Expand Down

0 comments on commit dd9dc13

Please sign in to comment.