-
Notifications
You must be signed in to change notification settings - Fork 30
51 lines (48 loc) · 1.49 KB
/
main.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
name: Build and Deploy
on:
push:
repository_dispatch:
types:
- toolbox-update-trigger
workflow_dispatch:
jobs:
build:
runs-on: self-ubuntu-24.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for all tags and branches
# - uses: actions/setup-python@v4
# with:
# python-version: '3.10'
# cache: 'pip' # caching pip dependencies
- name: Python install
run: |
python -m venv --system-site-packages .venv
source .venv/bin/activate
pip install -I -r requirements.txt
- name: Npm Install
run: |
npm i
echo "${{ github.workspace }}/node_modules/.bin" >> $GITHUB_PATH
- name: Check
run: |
npx antora -v
npx asciidoctor -v
- name: Build
run: |
source .venv/bin/activate
npm run antora
env:
FEELPP_GITHUB_TOKEN: ${{ secrets.DOCS_GITHUB_KEY }}
GITHUB_OAUTH: ${{ secrets.DOCS_GITHUB_KEY }}
ALGOLIA_API_KEY: ${{ secrets.ALGOLIA_API_KEY }}
ALGOLIA_INDEX_NAME: ${{ secrets.ALGOLIA_INDEX_NAME }}
ALGOLIA_APP_ID: ${{ secrets.ALGOLIA_APP_ID }}
- name: Deploy
uses: JamesIves/github-pages-deploy-action@v4
if: github.ref == 'refs/heads/master' || github.ref == 'refs/heads/develop'
with:
token: ${{ secrets.GITHUB_TOKEN }}
branch: gh-pages # The branch the action should deploy to.
folder: build/site # The folder the action should deploy.