diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..f53026b --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,25 @@ +name: Release + +on: + push: + tags: + - 'v*.*.*' + +permissions: + contents: write + packages: write + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + - uses: actions/setup-go@v5 + with: + go-version-file: go.mod + check-latest: true + - uses: goreleaser/goreleaser-action@v5 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.gitignore b/.gitignore index 84c048a..e2cae22 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ /build/ +/dist/ diff --git a/.go-version b/.go-version deleted file mode 100644 index 166a50f..0000000 --- a/.go-version +++ /dev/null @@ -1 +0,0 @@ -1.12.9 diff --git a/.goreleaser.yaml b/.goreleaser.yaml new file mode 100644 index 0000000..f3a3258 --- /dev/null +++ b/.goreleaser.yaml @@ -0,0 +1,15 @@ +# yaml-language-server: $schema=https://goreleaser.com/static/schema.json +version: 1 +builds: + - main: ./cmd/ejsonkms + env: + - CGO_ENABLED=0 + goos: + - darwin + - linux + - windows +archives: + - format: tar.gz + format_overrides: + - goos: windows + format: zip diff --git a/.travis.yml b/.travis.yml deleted file mode 100644 index 4d3a748..0000000 --- a/.travis.yml +++ /dev/null @@ -1,10 +0,0 @@ -language: go - -services: - - docker - -before_install: - - docker-compose build - -script: - - docker-compose run tests go test \ No newline at end of file diff --git a/Dockerfile b/Dockerfile index 1c255c7..3354f7c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM golang:1.16-alpine +FROM golang:1.21-alpine WORKDIR /go/src/github.com/envato/ejsonkms COPY . . RUN apk add git gcc musl-dev diff --git a/VERSION b/VERSION index 0ea3a94..0c62199 100644 --- a/VERSION +++ b/VERSION @@ -1 +1 @@ -0.2.0 +0.2.1 diff --git a/go.mod b/go.mod index a078cae..e35ac1e 100644 --- a/go.mod +++ b/go.mod @@ -1,14 +1,23 @@ module github.com/envato/ejsonkms -go 1.12 +go 1.21 require ( github.com/Shopify/ejson v1.2.1 github.com/Shopify/ejson2env v2.0.0+incompatible github.com/aws/aws-sdk-go v1.34.0 - github.com/dustin/gojson v0.0.0-20130803055424-057ac0edc14e // indirect github.com/kami-zh/go-capturer v0.0.0-20171211120116-e492ea43421d github.com/smartystreets/goconvey v0.0.0-20190731233626-505e41936337 - github.com/taskcluster/shell v0.0.0-20161108133149-4039a2cd6f88 // indirect github.com/urfave/cli v1.20.0 ) + +require ( + github.com/dustin/gojson v0.0.0-20130803055424-057ac0edc14e // indirect + github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1 // indirect + github.com/jmespath/go-jmespath v0.3.0 // indirect + github.com/jtolds/gls v4.20.0+incompatible // indirect + github.com/smartystreets/assertions v0.0.0-20180927180507-b2de0cb4f26d // indirect + github.com/taskcluster/shell v0.0.0-20161108133149-4039a2cd6f88 // indirect + golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 // indirect + golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a // indirect +) diff --git a/go.sum b/go.sum index 00d5a94..5350dc1 100644 --- a/go.sum +++ b/go.sum @@ -34,14 +34,11 @@ github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijb golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 h1:VklqNMn3ovrHsnt90PveolxSbWFaJdECFbxSq0Mqo2M= golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= -golang.org/x/net v0.0.0-20200202094626-16171245cfb2 h1:CCH4IOTTfewWjGOlSp+zGcjutRKlBEZQ6wTn8ozI/nI= golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a h1:1BGLXjeY4akVXGgbC9HugT3Jv3hCI0z56oJR5vAMgBU= golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= -golang.org/x/text v0.3.0 h1:g61tztE5qeGQ89tm6NTjjM9VPIm088od1l6aSorWRWg= golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= golang.org/x/tools v0.0.0-20190328211700-ab21143f2384/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= -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.2.2 h1:ZCJp+EgiOT7lHqUV2J862kp8Qj64Jo6az82+3Td9dZw= gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI=