-
-
Notifications
You must be signed in to change notification settings - Fork 0
86 lines (75 loc) · 2.58 KB
/
update-pages.yml
File metadata and controls
86 lines (75 loc) · 2.58 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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
---
name: Update
permissions: {}
on:
pull_request:
push:
branches:
- master
schedule:
- cron: '0 */3 * * *' # every 3 hours
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs:
update:
permissions:
contents: read
runs-on: ubuntu-latest
timeout-minutes: 60
steps:
- name: Checkout
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Setup python
uses: actions/setup-python@a309ff8b426b58ec0e2a45f0f869d46889d02405 # v6.2.0
with:
python-version: '3.14'
- name: Install Python dependencies
run: |
python -m pip install --upgrade pip setuptools wheel
python -m pip install .
- name: Collect data
env:
DASHBOARD_AUR_REPOS: sunshine,sunshine-bin,sunshine-git
CODECOV_TOKEN: ${{ secrets.CODECOV_API_TOKEN }}
DISCORD_INVITE: ${{ secrets.DISCORD_INVITE }}
FACEBOOK_GROUP_ID: ${{ secrets.FACEBOOK_GROUP_ID }}
FACEBOOK_PAGE_ID: ${{ secrets.FACEBOOK_PAGE_ID }}
FACEBOOK_TOKEN: ${{ secrets.FACEBOOK_ACCESS_TOKEN }}
GITHUB_REPOSITORY_OWNER: ${{ github.repository_owner }}
GITHUB_TOKEN: ${{ secrets.GH_BOT_TOKEN || secrets.GITHUB_TOKEN }}
PATREON_CAMPAIGN_ID: 6131567
READTHEDOCS_TOKEN: ${{ secrets.READTHEDOCS_TOKEN }}
THREADING_EXCEPTION_HANDLER: "true"
run: python -u -m src.updater
- name: Cat log
if: always()
run: cat ./logs/updater.log
- name: Build dashboard data
run: python -u -m src.builder
- name: Prepare Artifacts # uploading artifacts will fail if not zipped due to very large quantity of files
shell: bash
run: 7z a build.zip ./gh-pages/. ./gh-pages-template/.
- name: Upload artifact
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
with:
name: update
path: ${{ github.workspace }}/build.zip
if-no-files-found: error
include-hidden-files: true
retention-days: 1
call-jekyll-build:
needs: update
permissions:
contents: read
uses: LizardByte/LizardByte.github.io/.github/workflows/jekyll-build.yml@master
secrets:
GH_BOT_EMAIL: ${{ secrets.GH_BOT_EMAIL }}
GH_BOT_TOKEN: ${{ secrets.GH_BOT_TOKEN }}
with:
gh_bot_name: ${{ vars.GH_BOT_NAME }}
site_artifact: 'update'
extract_archive: 'build.zip'
target_branch: 'gh-pages'
clean_gh_pages: true