Build Privacy Policies #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Build Privacy Policies | |
on: | |
push: | |
branches: | |
- main | |
paths: | |
- 'assets/privacy_policy/**' | |
workflow_dispatch: | |
permissions: | |
contents: read | |
pages: write | |
id-token: write | |
jobs: | |
combine-and-publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Build privacy policies | |
run: | | |
mkdir -p public | |
for file in assets/privacy_policy/policy_zhHans.md assets/privacy_policy/policy_zhHant.md assets/privacy_policy/policy_yue.md assets/privacy_policy/policy_en.md; do | |
cat "$file" >> public/privacy_policy.md | |
echo "" >> public/privacy_policy.md | |
done | |
- name: Setup GitHub Pages | |
uses: actions/configure-pages@v2 | |
- name: Upload artifact | |
uses: actions/upload-pages-artifact@v1 | |
with: | |
path: 'public' | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v1 |