fix build
[yosql.git] / .github / workflows / main.yml
blobcd306a80e768d1bab61d5c79196809b69806d954
1 name: Main Branch Builds
2 on:
3   push:
4     branches: [ main ]
5 jobs:
6   linux:
7     name: Linux
8     runs-on: ubuntu-latest
9     steps:
10       - id: checkout
11         name: Clone Git Repository
12         uses: actions/checkout@v2
13       - id: java
14         name: Setup Java
15         uses: actions/setup-java@v1
16         with:
17           java-version: 15
18           java-package: jdk
19           architecture: x64
20       - id: cache
21         name: Cache Maven Repository
22         uses: actions/cache@v1
23         with:
24           path: ~/.m2/repository
25           key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
26           restore-keys: |
27             ${{ runner.os }}-maven-
28       - id: install
29         name: Install Project
30         run: mvn --batch-mode --settings $GITHUB_WORKSPACE/build/settings.xml --activate-profiles benchmarks install -Dorg.slf4j.simpleLogger.log.yosql=warn
31         env:
32           GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
33       - name: Copy Codegen Benchmark Results
34         run: cp ./yosql-benchmarks/yosql-benchmarks-codegen/target/benchmark/yosql-benchmarks-codegen.json ./yosql-website/content/benchmarks/current/yosql-benchmarks-codegen.json
35       - name: Copy JDBC Benchmark Results
36         run: cp ./yosql-benchmarks/yosql-benchmarks-jdbc/target/benchmark/yosql-benchmarks-jdbc.json ./yosql-website/content/benchmarks/current/yosql-benchmarks-jdbc.json
37       - id: hugo
38         name: Setup Hugo
39         uses: peaceiris/actions-hugo@v2
40         with:
41           hugo-version: latest
42       - name: Build Website
43         run: hugo --minify --i18n-warnings --path-warnings --source yosql-website
44       - name: Deploy Website
45         uses: peaceiris/actions-gh-pages@v3
46         with:
47           github_token: ${{ secrets.GITHUB_TOKEN }}
48           publish_dir: ./yosql-website/public
49           force_orphan: true
50           cname: yosql.projects.metio.wtf