-
Notifications
You must be signed in to change notification settings - Fork 14
51 lines (48 loc) · 1.71 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: Release
on:
push:
branches:
- main
permissions:
contents: write
jobs:
release:
name: Release
runs-on: windows-latest-16-cores
steps:
- name: Setup environment
run: |-
chcp 65001 #set code page to utf-8
echo ("GOPRIVATE=github.com/speakeasy-api") >> $env:GITHUB_ENV
- name: Checkout repository
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
fetch-depth: 0
- name: Conventional Commits
uses: TriPSs/conventional-changelog-action@3c4970b6573374889b897403d2f1278c395ea0df # v5.4.0
with:
github-token: ${{ secrets.github_token }}
skip-commit: "true"
output-file: "false"
skip-on-empty: "false"
preset: conventionalcommits
- uses: actions/setup-go@41dfa10bad2bb2ae585af6ee5bb4d7d973ad74ed # v5.1.0
with:
go-version-file: "go.mod"
# More assembly might be required: Docker logins, GPG, etc. It all depends
# on your needs.
- name: Configure git for private modules
run: git config --global url."https://speakeasybot:${{ secrets.BOT_REPO_TOKEN }}@github.com".insteadOf "https://github.com"
- name: Setup Choco
uses: crazy-max/ghaction-chocolatey@2ae99523e93879734d432250f87e2c45c379cd60 # v3.2.0
with:
args: --version
- name: goreleaser
uses: goreleaser/goreleaser-action@9ed2f89a662bf1735a48bc8557fd212fa902bebf # v6.1.0
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.BOT_REPO_TOKEN }}
CHOCOLATEY_API_KEY: ${{ secrets.CHOCOLATEY_API_KEY }}