-
Notifications
You must be signed in to change notification settings - Fork 1
40 lines (38 loc) · 1007 Bytes
/
ci.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
name: CI
on:
push:
pull_request:
workflow_dispatch:
env:
JDK_JAVA_OPTIONS: "--add-opens java.base/java.lang=ALL-UNNAMED --add-opens java.base/java.util=ALL-UNNAMED --add-opens java.base/java.io=ALL-UNNAMED"
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
java-version: 17
distribution: "adopt"
- name: Test
run: |
cd trunk/java
mvn --batch-mode test
deploy:
if: github.ref == 'refs/heads/master' && github.repository_owner == 'Codeforces'
needs: test
runs-on: windows-latest
permissions:
contents: read
packages: write
steps:
- uses: actions/checkout@v2
- uses: actions/setup-java@v2
with:
java-version: "17"
distribution: "adopt"
- name: Deploy
run: |
cd trunk/java
mvn --batch-mode deploy -DskipTests