diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml new file mode 100644 index 0000000..ff8d751 --- /dev/null +++ b/.github/workflows/release.yaml @@ -0,0 +1,26 @@ + +name: Release + +on: + push: + tags: + - '*' + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/setup-go@v2 + with: + go-version: '^1.15.6' + + - uses: goreleaser/goreleaser-action@v2 + with: + distribution: goreleaser + version: latest + args: release --rm-dist + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..849ddff --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +dist/ diff --git a/.goreleaser.yml b/.goreleaser.yml new file mode 100644 index 0000000..110b8ad --- /dev/null +++ b/.goreleaser.yml @@ -0,0 +1,28 @@ +env: + - GO111MODULE=on + +before: + hooks: + - go mod tidy + - go generate ./... + +builds: + - main: ./cmd/desync + goos: + - linux + - darwin + - windows + ignore: + - goos: darwin + goarch: arm64 + - goos: windows + goarch: arm64 + +checksum: + name_template: 'checksums.txt' + +snapshot: + name_template: "{{ incpatch .Version }}-next" + +changelog: + sort: asc