-
Notifications
You must be signed in to change notification settings - Fork 33
61 lines (53 loc) · 1.75 KB
/
release-by-changelog.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
52
53
54
55
56
57
58
59
60
61
name: Release by Changelog
on:
push:
branches:
- main
workflow_dispatch:
inputs:
branch:
description: 'Branch to create a release from'
required: true
default: 'main'
version:
description: 'Specify the semantic version for the release (vX.Y.Z)'
required: true
reason:
description: 'Reason for the manual release'
required: false
jobs:
release:
runs-on: ubuntu-latest
env:
GOPROXY: proxy.golang.org,direct
GOPRIVATE: github.com/c2fo,github.com/C2FO
# Give the workflow permission to read/write contents if needed
permissions:
contents: read
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
ref: ${{ github.event.inputs.branch || github.ref_name }}
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.24
- name: Configure git for private modules
run: |
go env -w GOPRIVATE=github.com/c2fo,github.com/C2FO
git config --global url."https://${{ secrets.GITHUB_TOKEN }}:[email protected]/".insteadOf "https://github.com/"
- name: Install and run ReleaseGen
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_REPOSITORY: ${{ github.repository }}
GITHUB_ACTOR: ${{ github.actor }}
GITHUB_REF_NAME: ${{ github.event.inputs.branch || github.ref_name }}
MANUAL_VERSION: ${{ github.event.inputs.version || '' }}
REASON: ${{ github.event.inputs.reason || '' }}
CUSTOM_CHANGE_TYPES: |
documentation:patch
run: |
go install github.com/c2fo/ep-tools/releasegen@latest
releasegen