-
Notifications
You must be signed in to change notification settings - Fork 159
66 lines (65 loc) · 2.43 KB
/
tag-and-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
57
58
59
60
61
62
63
64
65
66
on:
push:
tags:
- 'v*'
name: tag-and-release
jobs:
build:
runs-on: ubuntu-latest
name: build-and-testing
env:
JRELEASER_SDKMAN_CONSUMER_KEY: ${{ secrets.SDKMAN_CONSUMER_KEY }}
JRELEASER_SDKMAN_CONSUMER_TOKEN: ${{ secrets.SDKMAN_CONSUMER_TOKEN }}
JRELEASER_TWITTER_CONSUMER_KEY: ${{ secrets.TWITTER_CONSUMER_KEY }}
JRELEASER_TWITTER_CONSUMER_SECRET: ${{ secrets.TWITTER_CONSUMER_SECRET }}
JRELEASER_TWITTER_ACCESS_TOKEN: ${{ secrets.TWITTER_ACCESS_TOKEN }}
JRELEASER_TWITTER_ACCESS_TOKEN_SECRET: ${{ secrets.TWITTER_ACCESS_TOKEN_SECRET }}
JRELEASER_BLUESKY_PASSWORD: ${{ secrets.BLUESKY_PASSWORD }}
JRELEASER_GITHUB_TOKEN: ${{ secrets.BREW_GITHUB_TOKEN }}
JRELEASER_GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
JRELEASER_GPG_PUBLIC_KEY: ${{ secrets.GPG_PUBLIC_KEY }}
JRELEASER_GPG_SECRET_KEY: ${{ secrets.GPG_SECRET_KEY }}
JRELEASER_NEXUS2_USERNAME: ${{ secrets.OSSRH_USERNAME}}
JRELEASER_NEXUS2_PASSWORD: ${{ secrets.OSSRH_TOKEN }}
JRELEASER_VERSION: 1.15.0
steps:
- uses: actions/checkout@f43a0e5ff2bd294095638e18286ca9a3d1956744 # v3
with:
fetch-depth: 0
- name: install-java11
uses: actions/setup-java@0ab4596768b603586c0de567f2430c30f5b0d2b0 # v3
with:
java-version: 11
distribution: temurin
cache: gradle
- name: build-gradle
run: ./gradlew --no-daemon clean build installDist publish --build-cache --scan -s
- name: integration-test
run: |
export PATH=`pwd`/build/install/jbang/bin:$PATH
pastdir=`pwd`
cd itests
./test_suite.sh
./itests.sh
cd $pastdir
- name: version extract
id: version
run: |
RELEASE_VERSION=`cat build/tmp/version.txt`
echo "::set-output name=RELEASE_VERSION::$RELEASE_VERSION"
- name: Run JReleaser
uses: jreleaser/release-action@v2
env:
JRELEASER_PROJECT_VERSION: ${{steps.version.outputs.RELEASE_VERSION}}
with:
version: ${{ env.JRELEASER_VERSION }}
arguments: release
setup-java: false
- name: JReleaser output
if: always()
uses: actions/upload-artifact@a8a3f3ad30e3422c9c7b888a15615d19a852ae32 # v3
with:
name: jreleaser-release
path: |
out/jreleaser/trace.log
out/jreleaser/output.properties