Merge pull request #748 from MarcelCoding/mjml #1582
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: Deploy Manual | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
pre_deploy: | |
runs-on: ubuntu-20.04 | |
outputs: | |
should_skip: ${{ steps.skip_check.outputs.should_skip }} | |
steps: | |
- id: skip_check | |
uses: fkirc/skip-duplicate-actions@v5 | |
with: | |
concurrent_skipping: always | |
deploy: | |
needs: pre_deploy | |
if: needs.pre_deploy.outputs.should_skip != 'true' | |
runs-on: ubuntu-20.04 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install jq | |
run: sudo apt-get install -y jq | |
- uses: dtolnay/[email protected] | |
- run: cargo doc | |
- name: Setup mdBook | |
uses: peaceiris/actions-mdbook@v1 | |
with: | |
mdbook-version: '0.4.34' | |
- name: Build manual | |
run: mdbook build | |
working-directory: manual | |
- name: Build translated manual | |
run: mdbook build | |
working-directory: translation/zh-CN/manual-zh-CN | |
- name: Add rustdoc output | |
run: cp -r target/doc manual/book/rustdoc | |
- name: Add translated manual output | |
run: cp -r translation/zh-CN/manual-zh-CN/book manual/book/zh-CN | |
- name: Add homepage | |
run: cp -r homepage/* manual/book/ | |
- name: Deploy to GitHub pages | |
uses: JamesIves/[email protected] | |
with: | |
branch: gh-pages | |
folder: manual/book | |
single-commit: true | |
force: true |