39 lines
939 B
YAML
39 lines
939 B
YAML
name: Pages
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
schedule:
|
|
- cron: "30 0,12 * * *"
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
pages:
|
|
runs-on: ubuntu-latest
|
|
container: alpine:latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Install Dependencies
|
|
run: |
|
|
apk update
|
|
apk add brotli curl git grep
|
|
- name: Build
|
|
run: sh src/script.sh
|
|
- name: Compress
|
|
run: |
|
|
find . -name "oisd*.txt" -type f -print0 | xargs -0 gzip -f -k -9
|
|
find . -name "oisd*.txt" -type f -print0 | xargs -0 brotli -f -k -9
|
|
- name: Deploy
|
|
uses: peaceiris/actions-gh-pages@v3
|
|
with:
|
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
publish_dir: ./public
|
|
force_orphan: true
|
|
- name: 'Upload Artifact'
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: artifacts
|
|
path: ./tmp/
|
|
retention-days: 30
|