Skip to content

Generate Apps header and appdocs files #6

Generate Apps header and appdocs files

Generate Apps header and appdocs files #6

name: Generate Apps header and appdocs files
on:
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install Jinja2 requests contentful
- name: Generate Markdown files
env:
CONTENTFUL_ACCESS_TOKEN: ${{ secrets.CONTENTFUL_GRAPHQLTOKEN }}
run: |
python builds/gen_md_from_contenful.py template/meta/zh_head.jinja2 docs/apps/_include --override
python builds/gen_md_from_contenful.py template/meta/en_head.jinja2 i18n/en/docusaurus-plugin-content-docs/current/apps/_include --override
python builds/gen_md_from_contenful.py template/meta/zh_app.jinja2 docs/apps --ignore-list template/meta/skip_file.json
python builds/gen_md_from_contenful.py template/meta/en_app.jinja2 i18n/en/docusaurus-plugin-content-docs/current/apps --ignore-list template/meta/skip_file.json
- name: Commit and push changes
uses: stefanzweifel/git-auto-commit-action@v4
with:
commit_message: Automated generation product markdown header