-
Notifications
You must be signed in to change notification settings - Fork 1
54 lines (47 loc) · 1.65 KB
/
Copy pathrelease.yml
File metadata and controls
54 lines (47 loc) · 1.65 KB
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
name: Create Release
on:
push:
tags:
- '*'
jobs:
createRelease:
runs-on: ubuntu-24.04
permissions:
contents: write
steps:
- name: checkout
uses: actions/checkout@v7.0.0
- name: set up JDK
uses: actions/setup-java@v5.6.0
with:
distribution: 'temurin'
java-version: 17
- name: Build
run: ./gradlew scripting-host:assembleReleaseDist IdeaPlugin:buildPlugin
- name: Create info variables
id: variables
run: |
gradleVersion="$(cat gradle.properties | sed -n 's/version=//p')"
gitVersion="${GITHUB_REF#refs/*/}"
if [ "$gradleVersion" != "$gitVersion" ]; then
echo "gradle properties version ($gradleVersion) doesn't match git tag version ($gitVersion)"
exit 1
fi
echo "version=$gitVersion" >> $GITHUB_OUTPUT
- name: Get Changelog
id: changelog
run: |
echo 'changes<<END_OF_CHANGELOG' >> $GITHUB_OUTPUT
./gradlew -q getChangelog --project-version='${{ steps.variables.outputs.version }}' --no-links --no-header >> $GITHUB_OUTPUT
echo END_OF_CHANGELOG >> $GITHUB_OUTPUT
- name: Create Release
uses: softprops/action-gh-release@v3
with:
body: "${{ steps.changelog.outputs.changes }}"
fail_on_unmatched_files: true
files: |
scripting-host/build/distributions/scripting-host-release*.tar.gz
scripting-host/build/distributions/scripting-host-release*.zip
IdeaPlugin/build/distributions/IdeaPlugin-*.zip
draft: false
prerelease: false