-
Notifications
You must be signed in to change notification settings - Fork 0
49 lines (46 loc) · 1.22 KB
/
main.yml
File metadata and controls
49 lines (46 loc) · 1.22 KB
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
name: Update dashboard
permissions:
contents: write
on:
schedule:
- cron: '00 06 * * *'
workflow_dispatch:
jobs:
update-dashboard:
runs-on: ubuntu-latest
steps:
- name: Checkout main
uses: actions/checkout@v5
with:
path: main
- name: Checkout gh-pages
uses: actions/checkout@v5
with:
ref: gh-pages
path: gh-pages
- name: Download and process artifacts
working-directory: ./main
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
npm ci
node main
git config --global user.name "GitHub Actions"
git config --global user.email "username@users.noreply.github.com"
git add data
if git diff --cached --quiet; then
echo "No changes to commit."
else
git commit -m "Add artifacts from Playwright's CI"
git push
fi
- name: Publish dashboard
working-directory: ./gh-pages
run: |
git add .
if git diff --cached --quiet; then
echo "No changes to commit."
else
git commit -m "Update dashboard"
git push
fi