generated from Funz/algorithm-template
-
Notifications
You must be signed in to change notification settings - Fork 0
81 lines (78 loc) · 1.99 KB
/
ant.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
name: Java CI
on:
push:
branches: [ master ]
tags: [ 'v*.*' ]
pull_request:
branches: [ master ]
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macOS-latest]
java: [ 8 ]
runs-on: ${{ matrix.os }}
env:
GITHUB_PAT: ${{ secrets.GITHUB_TOKEN }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: ${{ matrix.java }}
java-package: jdk
- uses: r-lib/actions/setup-r@v2
with:
r-version: 4.2
- uses: r-lib/actions/setup-pandoc@v1
- run: |
WD=$PWD
cd ..
git clone https://github.com/Funz/funz-profile
cd $WD
shell: bash
- if: matrix.os == 'ubuntu-latest'
run: sudo apt-get -y install libharfbuzz-dev libfribidi-dev libcurl4-openssl-dev
- run: ant -noinput -buildfile build.xml test
id: anttest
continue-on-error: true
- if: steps.anttest.outcome != 'success'
uses: actions/upload-artifact@v2
with:
name: artifacts-${{ matrix.os }}-${{ matrix.java }}
path: |
*.txt
*.log
*.out
*.Rout
*.Rmd
*.md
*.html
- if: steps.anttest.outcome != 'success'
run: exit 1
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v1
with:
java-version: 1.8
java-package: jdk
- run: |
WD=$PWD
cd ..
git clone https://github.com/Funz/funz-profile
cd $WD
- run: |
ant clean dist
cd dist; zip -r ../algorithm-RandomSampling.zip *; cd ..
ant install
zip -r FunzR-RandomSampling.zip FunzR-RandomSampling
- uses: actions/upload-artifact@v2
with:
path: dist
- uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: ./*-RandomSampling.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}