From c497909213baf5146c3d115585737191469a2081 Mon Sep 17 00:00:00 2001 From: MATSUU Takuto Date: Sat, 7 Aug 2021 22:38:37 +0900 Subject: [PATCH 1/5] add github actions --- .github/workflows/branches.yaml | 22 ++++++++++++++++++++++ .github/workflows/tags.yaml | 22 ++++++++++++++++++++++ 2 files changed, 44 insertions(+) create mode 100644 .github/workflows/branches.yaml create mode 100644 .github/workflows/tags.yaml diff --git a/.github/workflows/branches.yaml b/.github/workflows/branches.yaml new file mode 100644 index 0000000..34e7e0c --- /dev/null +++ b/.github/workflows/branches.yaml @@ -0,0 +1,22 @@ +name: Release CLI to the GitHub Release +on: + push: + branches: + - '*' + +jobs: + release: + name: Release test + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/setup-go@v2 + with: + go-version: 1.16 + - uses: goreleaser/goreleaser-action@v2 + with: + args: release --rm-dist --skip-publish --snapshot + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/tags.yaml b/.github/workflows/tags.yaml new file mode 100644 index 0000000..4c12916 --- /dev/null +++ b/.github/workflows/tags.yaml @@ -0,0 +1,22 @@ +name: Release CLI to the GitHub Release +on: + push: + tags: + - '*' + +jobs: + release: + name: Release + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + with: + fetch-depth: 0 + - uses: actions/setup-go@v2 + with: + go-version: 1.16 + - uses: goreleaser/goreleaser-action@v2 + with: + args: release --rm-dist + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 1826b9adf1e858b2af16598c6531541b222970a8 Mon Sep 17 00:00:00 2001 From: MATSUU Takuto Date: Sat, 7 Aug 2021 23:02:11 +0900 Subject: [PATCH 2/5] remove --skip-publish --- .github/workflows/branches.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/branches.yaml b/.github/workflows/branches.yaml index 34e7e0c..df3b2f3 100644 --- a/.github/workflows/branches.yaml +++ b/.github/workflows/branches.yaml @@ -17,6 +17,6 @@ jobs: go-version: 1.16 - uses: goreleaser/goreleaser-action@v2 with: - args: release --rm-dist --skip-publish --snapshot + args: release --rm-dist --snapshot env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} From 4ebd231ddf56561196a4f75cb68a01b4acfef44e Mon Sep 17 00:00:00 2001 From: MATSUU Takuto Date: Mon, 23 Aug 2021 08:41:12 +0900 Subject: [PATCH 3/5] use latest go version --- .github/workflows/branches.yaml | 2 +- .github/workflows/tags.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/branches.yaml b/.github/workflows/branches.yaml index df3b2f3..034c0f2 100644 --- a/.github/workflows/branches.yaml +++ b/.github/workflows/branches.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: 1.16 + go-version: latest - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist --snapshot diff --git a/.github/workflows/tags.yaml b/.github/workflows/tags.yaml index 4c12916..caa2442 100644 --- a/.github/workflows/tags.yaml +++ b/.github/workflows/tags.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: 1.16 + go-version: latest - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist From 45d4dab984c88bf4ba64d62f8b8a20178ebb283e Mon Sep 17 00:00:00 2001 From: MATSUU Takuto Date: Mon, 23 Aug 2021 08:44:00 +0900 Subject: [PATCH 4/5] use latest 1.* versions --- .github/workflows/branches.yaml | 2 +- .github/workflows/tags.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/branches.yaml b/.github/workflows/branches.yaml index 034c0f2..160e24c 100644 --- a/.github/workflows/branches.yaml +++ b/.github/workflows/branches.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: latest + go-version: '^1\.' - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist --snapshot diff --git a/.github/workflows/tags.yaml b/.github/workflows/tags.yaml index caa2442..8955cb9 100644 --- a/.github/workflows/tags.yaml +++ b/.github/workflows/tags.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: latest + go-version: '^1\.' - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist From d51b97f4e57a53dfe8be97b5603d12e3d8d2d008 Mon Sep 17 00:00:00 2001 From: MATSUU Takuto Date: Mon, 23 Aug 2021 08:44:58 +0900 Subject: [PATCH 5/5] use 1.17 --- .github/workflows/branches.yaml | 2 +- .github/workflows/tags.yaml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/branches.yaml b/.github/workflows/branches.yaml index 160e24c..f90ce11 100644 --- a/.github/workflows/branches.yaml +++ b/.github/workflows/branches.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: '^1\.' + go-version: '1.17' - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist --snapshot diff --git a/.github/workflows/tags.yaml b/.github/workflows/tags.yaml index 8955cb9..5198ae8 100644 --- a/.github/workflows/tags.yaml +++ b/.github/workflows/tags.yaml @@ -14,7 +14,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v2 with: - go-version: '^1\.' + go-version: '1.17' - uses: goreleaser/goreleaser-action@v2 with: args: release --rm-dist