Skip to content

Commit

Permalink
cmd/wit-bindgen-go/cmd: update to github.com/urfave/cli API changes
Browse files Browse the repository at this point in the history
  • Loading branch information
ydnar committed Jan 26, 2024
1 parent 8ff8977 commit 58de016
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
5 changes: 3 additions & 2 deletions cmd/wit-bindgen-go/cmd/print/print.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package print

import (
"context"
"fmt"

"github.com/ydnar/wasm-tools-go/internal/witcli"
Expand All @@ -16,8 +17,8 @@ var Command = &cli.Command{
Action: action,
}

func action(ctx *cli.Context) error {
res, err := witcli.LoadOne(ctx.Args().Slice()...)
func action(ctx context.Context, cmd *cli.Command) error {
res, err := witcli.LoadOne(cmd.Args().Slice()...)
if err != nil {
return err
}
Expand Down
5 changes: 3 additions & 2 deletions cmd/wit-bindgen-go/cmd/syntax/syntax.go
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package syntax

import (
"context"
"fmt"

"github.com/urfave/cli/v3"
Expand All @@ -14,8 +15,8 @@ var Command = &cli.Command{
Action: action,
}

func action(ctx *cli.Context) error {
res, err := witcli.LoadOne(ctx.Args().Slice()...)
func action(ctx context.Context, cmd *cli.Command) error {
res, err := witcli.LoadOne(cmd.Args().Slice()...)
if err != nil {
return err
}
Expand Down

0 comments on commit 58de016

Please sign in to comment.