forked from Framstag/libosmscout
-
Notifications
You must be signed in to change notification settings - Fork 0
64 lines (53 loc) · 1.68 KB
/
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
name: Release
on:
workflow_dispatch:
inputs:
version:
description: 'Release version'
required: true
env:
JAVA_VERSION: '17'
JAVA_DISTRO: 'zulu'
jobs:
create_release:
name: Create release
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: master
fetch-depth: 0
- name: Install gcc compiler and Co
run: sudo apt-get -y install gcc-12 g++-12 libtbb-dev ccache libtool pkg-config
- name: Install meson and ninja via pip
run: "pip install meson ninja"
- name: Set version
run: |
VERSION=${{ github.event.inputs.version }}
sed -i "s/^ *version: *'[0-9a-z.-]*', *$/ version: '${VERSION}',/g" meson.build
- name: Initialize meson project
run: meson setup dist --wrap-mode nofallback
env:
CXX: g++-12
CC: gcc-12
- name: Create distribution archive
run: meson dist -C dist --formats "xztar,zip" --no-tests --allow-dirty
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
java-version: ${{ env.JAVA_VERSION }}
distribution: ${{ env.JAVA_DISTRO }}
- name: JReleaser full-release
uses: jreleaser/release-action@v2
env:
JRELEASER_PROJECT_VERSION: ${{ github.event.inputs.version }}
JRELEASER_GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: JReleaser upload output
uses: actions/upload-artifact@v4
if: ${{ always() }}
with:
name: jreleaser-release
path: |
out/jreleaser/trace.log
out/jreleaser/output.properties