Skip to content

Conversation

@rssnyder
Copy link
Contributor

The current go plugin example code does not work out of the box with go 1.19:

➜  drone-plugin-go git:(main) ✗ GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o webhook
# github.com/rssnyder/drone-plugin-go
./plugin.go:9:11: undefined: strings
./plugin.go:10:8: undefined: os.GetEnv
./plugin.go:13:3: req declared but not used
./plugin.go:14:8: undefined: os.GetEnv
./plugin.go:15:8: undefined: os.GetEnv
  • GetEnv->Getenv
  • import strings
  • use blank identifier
  • ran go fmt
➜  drone-plugin-go git:(main) ✗ GOOS=linux GOARCH=amd64 CGO_ENABLED=0 go build -o webhook
➜  drone-plugin-go git:(main) ✗ go fmt
plugin.go

Copy link
Contributor

@d1wilko d1wilko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@d1wilko d1wilko merged commit 94c080d into drone:master Jan 17, 2023
@rssnyder rssnyder deleted the patch-1 branch January 17, 2023 14:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants