-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (51 loc) · 1.5 KB
/
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
58
59
60
name: deploy
on:
push:
workflow_dispatch:
concurrency:
group: pages
cancel-in-progress: true
jobs:
build-app:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v3
with:
node-version: 20.16.0
- uses: borales/actions-yarn@v4
with:
cmd: install
- name: install angular
run: npm install -g @angular/cli@17
- name: build app
run: ng build --output-path ild-phoenix-app --base-href /Phoenix-ILD/
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: ild-phoenix-app
publish-doc:
needs: build-app
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
ref: gh-pages
- name: remove build file
run: rm -rf $GITHUB_WORKSPACE/*
- uses: actions/download-artifact@v4
with:
name: github-pages
path: doc_artifact
- name: update build file
run: |
tar -xvf doc_artifact/artifact.tar --directory ${GITHUB_WORKSPACE}
rm -r doc_artifact
- name: commit and push
env:
GITHUB_TOKEN: ${{ secrets.PHOENIX_ILD }}
run: |
git config --global user.email ${GITHUB_ACTOR_ID}+${GITHUB_ACTOR}@users.noreply.github.com
git config --global user.name ${GITHUB_ACTOR}
git add .
git diff-index --quiet HEAD 2>&1 > /dev/null || git commit -m "Update detector files for Phoenix-ILD" && git push