We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7363caf commit b45c71dCopy full SHA for b45c71d
main.go
@@ -2,9 +2,11 @@ package main
2
3
import (
4
"context"
5
+ "errors"
6
"os"
7
8
"github.com/charmbracelet/log"
9
+ "github.com/cli/go-gh/v2"
10
"github.com/flexwie/ghs/pkg"
11
"github.com/urfave/cli/v2"
12
)
@@ -30,6 +32,11 @@ func main() {
30
32
{Name: "Felix Wieland", Email: "ghs@felixwie.com"},
31
33
},
34
Action: func(ctx *cli.Context) error {
35
+ _, err := gh.Path()
36
+ if err != nil {
37
+ return errors.New("gh cli is not installed")
38
+ }
39
+
40
gist := ctx.Args().Get(0)
41
if len(gist) == 0 {
42
return cli.Exit("no gist provided", 2)
0 commit comments