From 91553dbd1eac2bde6329edd99b2eab4c0a0df0ec Mon Sep 17 00:00:00 2001 From: Ilia Sergunin Date: Sun, 26 Nov 2023 22:58:13 +0300 Subject: [PATCH] 1. Added release --- .github/workflows/release.yml | 41 +++++++++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..6d7aef6 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,41 @@ +name: release + +on: + push: + tags: + - v* + +env: + GO_VERSION: "1.21" + +jobs: + + GoReleaser: + name: release + runs-on: ubuntu-latest + steps: + + - uses: actions/checkout@v4 + with: + fetch-depth: 0 + + - uses: actions/setup-go@v4 + with: + go-version: ${{ env.GO_VERSION }} + + - uses: actions/cache@v3 + if: ${{ !env.ACT }} + with: + path: ~/go/pkg/mod + key: ${{ runner.os }}-go-${{ matrix.golang }}-${{ hashFiles('**/go.sum') }} + restore-keys: | + ${{ runner.os }}-go-${{ matrix.golang }}- + + - name: GoReleaser + uses: goreleaser/goreleaser-action@v5 + with: + version: latest + args: release --clean + workdir: cmd/ + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file