Merge pull request #238152 from BenediktBroich/twitch-cli

twitch-cli: init at 1.1.19
This commit is contained in:
figsoda 2023-06-17 08:35:23 -04:00 committed by GitHub
commit f36ffd059b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 64 additions and 0 deletions

View File

@ -0,0 +1,13 @@
diff --git a/cmd/root.go b/cmd/root.go
index 3d85c19..cbbe40c 100644
--- a/cmd/root.go
+++ b/cmd/root.go
@@ -16,7 +16,7 @@ import (
var cfgFile string
var rootCmd = &cobra.Command{
- Use: "twitch",
+ Use: "twitch-cli",
Short: "A simple CLI tool for the New Twitch API and Webhook products.",
}

View File

@ -0,0 +1,49 @@
{ buildGoModule
, fetchFromGitHub
, lib
, testers
, twitch-cli
}:
buildGoModule rec {
pname = "twitch-cli";
version = "1.1.19";
src = fetchFromGitHub {
owner = "twitchdev";
repo = pname;
rev = "v${version}";
hash = "sha256-osR7+oQ0QBIk/OrMb4Txhb31zELi+eoM47GsWgF/PAg=";
};
patches = [
./application-name.patch
];
vendorHash = "sha256-OhcRMXY8s+XciF+gV3cZ8fxtzo9+I76tBPZ0xG8ddHU=";
ldflags = [
"-s"
"-w"
"-X=main.buildVersion=${version}"
];
preCheck = ''
export HOME=$(mktemp -d)
'';
__darwinAllowLocalNetworking = true;
passthru.tests.version = testers.testVersion {
package = twitch-cli;
command = "HOME=$(mktemp -d) ${pname} version";
version = "${pname}/${version}";
};
meta = with lib; {
description = "The official Twitch CLI to make developing on Twitch easier";
homepage = "https://github.com/twitchdev/twitch-cli";
license = licenses.asl20;
maintainers = with maintainers; [ benediktbroich ];
};
}

View File

@ -40106,6 +40106,8 @@ with pkgs;
tvheadend = callPackage ../servers/tvheadend { };
twitch-cli = callPackage ../development/tools/twitch-cli { };
twiggy = callPackage ../development/tools/twiggy { };
uacme = callPackage ../tools/admin/uacme { };