Commit 34dd0d96 authored by Scott Edlund's avatar Scott Edlund
Browse files

stc-cli: add -version

parent a882bca3
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
{
  lib,
  buildGoModule,
  fetchFromGitHub,
  lib,
  versionCheckHook,
}:

buildGoModule rec {
@@ -17,6 +18,12 @@ buildGoModule rec {

  vendorHash = "sha256-qLpWXikTr+vB2bIw2EqnoJ0uOxUc/qc6SdGEJQXwmTQ=";

  ldflags = [ "-X main.GitTag=${version}" ];

  doInstallCheck = true;
  nativeInstallCheckInputs = [ versionCheckHook ];
  versionCheckProgramArg = "-version";

  meta = {
    description = "Syncthing CLI Tool";
    homepage = "https://github.com/tenox7/stc";