-
-
Notifications
You must be signed in to change notification settings - Fork 3
87 lines (75 loc) · 3.18 KB
/
graalvm.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
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
name: GraalVM Build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- name: Setup GraalVM action
# You may pin to the exact commit or the version.
# uses: ayltai/setup-graalvm@eb0db9af1ceb6dadb398847c7e23fc3afa09c0d3
uses: ayltai/setup-graalvm@master
with:
# The JDK version to be installed with GraalVM. E.g. 8, 11. See https://github.com/graalvm/graalvm-ce-builds/releases
java-version: 11 # optional
# The version of GraalVM to make available on PATH. E.g. 20.1.0, 19.3.2. See https://github.com/graalvm/graalvm-ce-builds/releases
# Allineare la versione con pom.xml
graalvm-version: 21.3.0
# Install GraalVM Native Image
native-image: true # optional
- name: Checkout repository
uses: actions/checkout@v4
with:
# We must fetch at least the immediate parents so that if this is
# a pull request then we can checkout the head.
fetch-depth: 2
- name: Windows msvc setup
uses: ilammy/msvc-dev-cmd@v1.12.1
if: ${{ matrix.os == 'windows-latest' }}
- name: Windows msbuild setup
uses: microsoft/setup-msbuild@v1
if: ${{ matrix.os == 'windows-latest' }}
- name: Call maven
run: mvn --no-transfer-progress -B package --file pom.xml -DskipNativeVersion=false
- name: Commit files
if: ${{ matrix.os == 'windows-latest' }}
run: |
dir D:\a\html2pop3\html2pop3\target\
copy D:\a\html2pop3\html2pop3\target\html2pop3.exe D:\a\html2pop3\html2pop3\executable\windows
copy D:\a\html2pop3\html2pop3\target\html2pop3-*.exe D:\a\html2pop3\html2pop3\executable\windows
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add *.exe
git commit -m "[Automated] Added Windows build files"
git pull
- name: Commit files
if: ${{ matrix.os == 'ubuntu-latest' }}
run: |
cp /home/runner/work/html2pop3/html2pop3/target/HTML2POP3 /home/runner/work/html2pop3/html2pop3/executable/linux/
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add .
git commit -m "[Automated] Added Linux build files"
git pull
- name: Commit files
if: ${{ matrix.os == 'macos-latest' }}
run: |
cp /Users/runner/work/html2pop3/html2pop3/target/html2pop3 /Users/runner/work/html2pop3/html2pop3/executable/mac/
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add .
git commit -m "[Automated] Added Mac build files"
git pull
# - name: Push changes
# uses: ad-m/github-push-action@master
# with:
# github_token: ${{ secrets.GITHUB_TOKEN }}
# branch: ${{ github.ref }}