Skip to content

Commit ead4413

Browse files
stainless-app[bot]yjp20
authored andcommitted
feat: now ships with manpages
1 parent 30949b8 commit ead4413

File tree

5 files changed

+208
-102
lines changed

5 files changed

+208
-102
lines changed

.goreleaser.yml

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,10 @@ version: 2
44
before:
55
hooks:
66
- mkdir -p completions
7-
- sh -c "go run ./cmd/stl/main.go completion bash > completions/stl.bash"
8-
- sh -c "go run ./cmd/stl/main.go completion zsh > completions/stl.zsh"
9-
- sh -c "go run ./cmd/stl/main.go completion fish > completions/stl.fish"
7+
- sh -c "go run ./cmd/stl/main.go @completion bash > completions/stl.bash"
8+
- sh -c "go run ./cmd/stl/main.go @completion zsh > completions/stl.zsh"
9+
- sh -c "go run ./cmd/stl/main.go @completion fish > completions/stl.fish"
10+
- sh -c "go run ./cmd/stl/main.go @manpages -o man"
1011

1112
builds:
1213
- id: macos
@@ -69,10 +70,15 @@ nfpms:
6970
maintainer: [email protected]
7071
bindir: /usr
7172
formats:
73+
- apk
7274
- deb
7375
- rpm
74-
75-
brews:
76+
- termux.deb
77+
- archlinux
78+
contents:
79+
- src: man/man1/*.1.gz
80+
dst: /usr/share/man/man1/
81+
homebrew_casks:
7682
- name: stl
7783
repository:
7884
owner: stainless-api
@@ -81,11 +87,13 @@ brews:
8187
homepage: https://stainless.com
8288
description: The official CLI for stainless.
8389
license: Apache-2.0
84-
install: |
85-
bin.install "stl"
86-
bash_completion.install "completions/stl.bash" => "stl"
87-
zsh_completion.install "completions/stl.zsh" => "_stl"
88-
fish_completion.install "completions/stl.fish"
90+
binary: "stl"
91+
completions:
92+
bash: "completions/stl.bash"
93+
zsh: "completions/stl.zsh"
94+
fish: "completions/stl.fish"
95+
manpages:
96+
- man/man1/stl.1.gz
8997

9098
notarize:
9199
macos:

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,14 @@ brew install stl
2525
go install 'github.com/stainless-api/stainless-api-cli/cmd/stl@latest'
2626
```
2727

28+
### Running Locally
29+
30+
<!-- x-release-please-start-version -->
31+
32+
```sh
33+
go run cmd/stl/main.go
34+
```
35+
2836
<!-- x-release-please-end -->
2937

3038
## Usage

go.mod

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ module github.com/stainless-api/stainless-api-cli
22

33
go 1.23.0
44

5-
toolchain go1.24.6
5+
toolchain go1.24.7
66

77
require (
88
github.com/charmbracelet/bubbles v0.21.0
@@ -17,6 +17,7 @@ require (
1717
github.com/tidwall/gjson v1.17.0
1818
github.com/tidwall/pretty v1.2.1
1919
github.com/tidwall/sjson v1.2.5
20+
github.com/urfave/cli-docs/v3 v3.0.0-alpha6
2021
github.com/urfave/cli/v3 v3.3.2
2122
golang.org/x/term v0.34.0
2223
)
@@ -32,6 +33,7 @@ require (
3233
github.com/charmbracelet/x/exp/slice v0.0.0-20250327172914-2fdc97757edf // indirect
3334
github.com/charmbracelet/x/exp/strings v0.0.0-20240722160745-212f7b056ed0 // indirect
3435
github.com/charmbracelet/x/term v0.2.1 // indirect
36+
github.com/cpuguy83/go-md2man/v2 v2.0.2 // indirect
3537
github.com/dlclark/regexp2 v1.11.0 // indirect
3638
github.com/dustin/go-humanize v1.0.1 // indirect
3739
github.com/erikgeiser/coninput v0.0.0-20211004153227-1c3628e74d0f // indirect
@@ -47,6 +49,7 @@ require (
4749
github.com/muesli/reflow v0.3.0 // indirect
4850
github.com/muesli/termenv v0.16.0 // indirect
4951
github.com/rivo/uniseg v0.4.7 // indirect
52+
github.com/russross/blackfriday/v2 v2.1.0 // indirect
5053
github.com/tidwall/match v1.1.1 // indirect
5154
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e // indirect
5255
github.com/yuin/goldmark v1.7.8 // indirect

go.sum

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ github.com/charmbracelet/x/termios v0.1.1 h1:o3Q2bT8eqzGnGPOYheoYS8eEleT5ZVNYNy8
4848
github.com/charmbracelet/x/termios v0.1.1/go.mod h1:rB7fnv1TgOPOyyKRJ9o+AsTU/vK5WHJ2ivHeut/Pcwo=
4949
github.com/charmbracelet/x/xpty v0.1.2 h1:Pqmu4TEJ8KeA9uSkISKMU3f+C1F6OGBn8ABuGlqCbtI=
5050
github.com/charmbracelet/x/xpty v0.1.2/go.mod h1:XK2Z0id5rtLWcpeNiMYBccNNBrP2IJnzHI0Lq13Xzq4=
51+
github.com/cpuguy83/go-md2man/v2 v2.0.2 h1:p1EgwI/C7NhT0JmVkwCD2ZBK8j4aeHQX2pMHHBfMQ6w=
52+
github.com/cpuguy83/go-md2man/v2 v2.0.2/go.mod h1:tgQtvFlXSQOSOSIRvRPT7W67SCa46tRHOmNcaadrF8o=
5153
github.com/creack/pty v1.1.24 h1:bJrF4RRfyJnbTJqzRLHzcGaZK1NeM5kTC9jGgovnR1s=
5254
github.com/creack/pty v1.1.24/go.mod h1:08sCNb52WyoAwi2QDyzUCTgcvVFhUzewun7wtTfvcwE=
5355
github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c=
@@ -93,6 +95,8 @@ github.com/rivo/uniseg v0.1.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJ
9395
github.com/rivo/uniseg v0.2.0/go.mod h1:J6wj4VEh+S6ZtnVlnTBMWIodfgj8LQOQFoIToxlJtxc=
9496
github.com/rivo/uniseg v0.4.7 h1:WUdvkW8uEhrYfLC4ZzdpI2ztxP1I582+49Oc5Mq64VQ=
9597
github.com/rivo/uniseg v0.4.7/go.mod h1:FN3SvrM+Zdj16jyLfmOkMNblXMcoc8DfTHruCPUcx88=
98+
github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk=
99+
github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM=
96100
github.com/stainless-api/stainless-api-go v0.24.0 h1:74rVOCsNiZFzp5WiNFZAF+0WPriyUdaQezUIDRzoqUo=
97101
github.com/stainless-api/stainless-api-go v0.24.0/go.mod h1:9Q2t8xq6EFgw8HYOsVxqKEfSDVe9eqCoh1zC0HMRwTY=
98102
github.com/stretchr/testify v1.10.0 h1:Xv5erBjTwe/5IxqUQTdXv5kgmIvbHo3QQyRwhJsOfJA=
@@ -107,6 +111,8 @@ github.com/tidwall/pretty v1.2.1 h1:qjsOFOWWQl+N3RsoF5/ssm1pHmJJwhjlSbZ51I6wMl4=
107111
github.com/tidwall/pretty v1.2.1/go.mod h1:ITEVvHYasfjBbM0u2Pg8T2nJnzm8xPwvNhhsoaGGjNU=
108112
github.com/tidwall/sjson v1.2.5 h1:kLy8mja+1c9jlljvWTlSazM7cKDRfJuR/bOJhcY5NcY=
109113
github.com/tidwall/sjson v1.2.5/go.mod h1:Fvgq9kS/6ociJEDnK0Fk1cpYF4FIW6ZF7LAe+6jwd28=
114+
github.com/urfave/cli-docs/v3 v3.0.0-alpha6 h1:w/l/N0xw1rO/aHRIGXJ0lDwwYFOzilup1qGvIytP3BI=
115+
github.com/urfave/cli-docs/v3 v3.0.0-alpha6/go.mod h1:p7Z4lg8FSTrPB9GTaNyTrK3ygffHZcK3w0cU2VE+mzU=
110116
github.com/urfave/cli/v3 v3.3.2 h1:BYFVnhhZ8RqT38DxEYVFPPmGFTEf7tJwySTXsVRrS/o=
111117
github.com/urfave/cli/v3 v3.3.2/go.mod h1:FJSKtM/9AiiTOJL4fJ6TbMUkxBXn7GO9guZqoZtpYpo=
112118
github.com/xo/terminfo v0.0.0-20220910002029-abceb7e1c41e h1:JVG44RsyaB9T2KIHavMF/ppJZNG9ZpyihvCd0w101no=

0 commit comments

Comments
 (0)