-
Notifications
You must be signed in to change notification settings - Fork 0
39 lines (37 loc) · 1.14 KB
/
prepare-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
name: Prepare Release
on:
push:
branches:
- main
workflow_dispatch:
inputs:
type:
description: Bump versions and trigger a new release.
required: true
default: release
options:
- release
- prerelease
jobs:
prepare-release:
runs-on: ubuntu-latest
env:
GITHUB_TOKEN: ${{ secrets.PAT }}
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
token: ${{ secrets.PAT }}
- name: Install Knope
uses: knope-dev/action@v1
with:
version: 0.7.0 # Test before updating, breaking changes likely: https://github.com/knope-dev/action#install-latest-version
- run: |
git config --global user.name "${{ github.triggering_actor }}"
git config --global user.email "${{ github.triggering_actor}}@users.noreply.github.com"
- name: Prepare Prerelease
run: knope --prerelease-label rc release
if: github.event_name == 'push' || (github.event_name == 'workflow_dispatch' && inputs.type == 'prerelease')
- name: Prepare Release
run: knope release
if: github.event_name == 'workflow_dispatch'