diff --git a/go.mod b/go.mod index 69adc0b..cfc1ba4 100644 --- a/go.mod +++ b/go.mod @@ -4,5 +4,5 @@ go 1.14 require ( github.com/stretchr/testify v1.6.1 - github.com/tomhjp/gh-action-jira v0.1.1 + github.com/tomhjp/gh-action-jira v0.2.0 ) diff --git a/go.sum b/go.sum index 793b80f..76cdc86 100644 --- a/go.sum +++ b/go.sum @@ -7,10 +7,8 @@ github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZN github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= github.com/stretchr/testify v1.6.1 h1:hDPOHmpOpP40lSULcqw7IrRb/u7w6RpDC9399XyoNd0= github.com/stretchr/testify v1.6.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg= -github.com/tomhjp/gh-action-jira v0.1.0 h1:7/0uQCxCT0mQ5cYGaAV0A3bGo/55jyhHaDNLvvl1qF0= -github.com/tomhjp/gh-action-jira v0.1.0/go.mod h1:ToAaW7uKSN8UP2aztAkiMl2ShRtn0n7vRkN1visxwFc= -github.com/tomhjp/gh-action-jira v0.1.1 h1:QST7UUVzfmCp3hyWsq8fiiikNmeLsjzRKte05bN1wcM= -github.com/tomhjp/gh-action-jira v0.1.1/go.mod h1:ToAaW7uKSN8UP2aztAkiMl2ShRtn0n7vRkN1visxwFc= +github.com/tomhjp/gh-action-jira v0.2.0 h1:koH3xdQjDGCY5oY7AFmdDfvorJWIee2MQ9UZKkgVwUk= +github.com/tomhjp/gh-action-jira v0.2.0/go.mod h1:ToAaW7uKSN8UP2aztAkiMl2ShRtn0n7vRkN1visxwFc= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405 h1:yhCVgyC4o1eVCa2tZl7eS0r+SDo693bJlVdllGtEeKM= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/yaml.v2 v2.3.0 h1:clyUAQHOM3G0M3f5vQj7LuJrETvjVot3Z5el9nffUtU= diff --git a/main.go b/main.go index 511b5c7..7c6add6 100644 --- a/main.go +++ b/main.go @@ -11,6 +11,7 @@ import ( "github.com/tomhjp/gh-action-jira/config" "github.com/tomhjp/gh-action-jira/format" + "github.com/tomhjp/gh-action-jira/gha" "github.com/tomhjp/gh-action-jira/jira" ) @@ -53,9 +54,9 @@ func create() error { fmt.Printf("Created issue %s\n", key) - // Special format log line to set output for the action. - // See https://docs.github.com/en/actions/creating-actions/metadata-syntax-for-github-actions#outputs-for-composite-run-steps-actions. - fmt.Printf("::set-output name=key::%s\n", key) + if err := gha.SetOutput("key", key); err != nil { + return err + } return nil }