mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-04 03:53:56 +00:00
571c71e6f7
We are migrating packages that meet below requirements: 1. using `callPackage` 2. called path is a directory 3. overriding set is empty (`{ }`) 4. not containing path expressions other than relative path (to makenixpkgs-vet happy) 5. not referenced by nix files outside of the directory, other than`pkgs/top-level/all-packages.nix` 6. not referencing nix files outside of the directory 7. not referencing `default.nix` (since it's changed to `package.nix`) 8. `outPath` doesn't change after migration The tool is here: https://github.com/Aleksanaa/by-name-migrate.
42 lines
948 B
Nix
42 lines
948 B
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitLab
|
|
, gitUpdater
|
|
}:
|
|
|
|
buildGoModule rec {
|
|
pname = "signaldctl";
|
|
version = "0.6.1";
|
|
src = fetchFromGitLab {
|
|
owner = "signald";
|
|
repo = "signald-go";
|
|
rev = "v${version}";
|
|
hash = "sha256-lMJyr4BPZ8V2f//CUkr7CVQ6o8nRyeLBHMDEyLcHSgQ=";
|
|
};
|
|
|
|
vendorHash = "sha256-LGIWAVhDJCg6Ox7U4ZK15K8trjsvSZm4/0jNpIDmG7I=";
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
|
|
mkdir -p $out/bin
|
|
# install only the binary and not any intermediate artifacts like
|
|
# `generators` which is only used during build
|
|
cp "$GOPATH/bin/signaldctl" $out/bin
|
|
|
|
runHook postInstall
|
|
'';
|
|
|
|
passthru.updateScript = gitUpdater {
|
|
rev-prefix = "v";
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "Golang library for communicating with signald";
|
|
mainProgram = "signaldctl";
|
|
homepage = "https://signald.org/signaldctl/";
|
|
license = licenses.gpl3;
|
|
maintainers = with maintainers; [ colinsane ];
|
|
};
|
|
}
|