-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (47 loc) · 1.53 KB
/
znai-pages-deploy.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
name: Publish Documentation
on:
push:
paths:
- "docs/**" # Publish only when docs are changed
branches:
- main # Publish only when changes are pushed to main branch
# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
permissions:
contents: read
pages: write
id-token: write
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: git fetch --prune --unshallow
# Set up java and maven
- name: Set up JDK 17
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: '17'
java-package: 'jdk'
# You'll need graphviz if you're generating diagrams
- name: Set up graphviz
run: sudo apt-get install graphviz
# Use virtual frame buffer to render images
- name: Build with xvfb enabled
uses: GabrielBB/[email protected]
# build documentation using maven.
with:
run: mvn -B -f docs/pom.xml znai:build
# Prepare pages for your repository
- name: Setup Pages
uses: actions/configure-pages@v4
# Create pages artifact. Change `path` to `docs/target/<your-project-name>
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
# Change `path` to `docs/target/<your-project-name>
path: 'docs/target/brainterpreter'
# Publish artifact on GitHub pages
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4