-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
56 lines (51 loc) · 2.09 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
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
name: "Prepare release"
on:
workflow_dispatch:
inputs:
last_minor:
description: "Next release after this one is going to be a major (don't check on patch-level releases)"
type: boolean
default: false
jobs:
prepare:
runs-on: ubuntu-latest
env:
BUNDLE_ONLY: "release"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v3
- uses: ruby/setup-ruby@v1
with:
ruby-version: "3.2"
bundler-cache: true
- id: pipeline_context
uses: ./.github/actions/extract_pipeline_context
with:
last_minor: ${{ inputs.last_minor }}
- name: "Bump version"
run: bin/release/bump-version ${{ steps.pipeline_context.outputs.candidate_version }}
- name: "Bump docker image version"
if: github.ref_name == 'main'
run: bin/release/bump-docker-image-version ${{ steps.pipeline_context.outputs.candidate_version }}
- name: "Bump installer starter frontend version"
if: github.ref_name == 'main'
run: bin/release/bump-starter-frontend-version ${{ steps.pipeline_context.outputs.candidate_patch_branch }}
- name: "Update Changelog"
run: bin/release/update-changelog ${{ steps.pipeline_context.outputs.candidate_tag }}
- name: "Compute labels for the PR"
id: pr_labels
run: |
if [ ${{ inputs.last_minor }} == 'true' ]; then
last_minor_label="release:generate-last_minor"
else
last_minor_label=""
fi
echo "labels='changelog:skip release:generate $last_minor_label'" >> $GITHUB_OUTPUT
- uses: ./.github/actions/commit_and_submit_pull_request
with:
labels: ${{ steps.pr_labels.outputs.labels }}
message: |
Prepare release for Solidus ${{ steps.pipeline_context.outputs.candidate_tag }}
This code has been automatically generated by our 'Prepare release' GitHub
action.
The actual release is not part of the automation, and it still needs to be manually done by a maintainer.