-
Notifications
You must be signed in to change notification settings - Fork 3
45 lines (38 loc) · 1.33 KB
/
spring-find-release-version.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
name: Find Current Version to Release
on:
workflow_call:
outputs:
releaseVersion:
description: Current Milestone to release
value: ${{ jobs.find-release-version.outputs.releaseVersion }}
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
find-release-version:
runs-on: ubuntu-latest
outputs:
releaseVersion: ${{ steps.find-milestone.outputs.milestone }}
steps:
- uses: actions/checkout@v4
with:
show-progress: false
- name: Checkout Common Repo
uses: actions/checkout@v4
with:
repository: spring-io/spring-github-workflows
path: spring-github-workflows
show-progress: false
ref: ${{ env.WORKFLOWS_REF }}
- name: Find Scheduled Milestone
id: find-milestone
uses: ./spring-github-workflows/.github/actions/spring-scheduled-milestone-for-branch
- name: Version to Release
run: |
RELEASE_VERSION=${{ steps.find-milestone.outputs.milestone }}
if [ -z $RELEASE_VERSION ]
then
gh run cancel ${{ github.run_id }}
echo "::warning title=Nothing to release::No scheduled milestone for ${{ steps.find-milestone.outputs.currentVersion }} version"
else
echo "::notice title=RELEASE VERSION::$RELEASE_VERSION"
fi