fix YAML syntax for arithmatex #6
This file contains hidden or 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 MkDocs | |
| on: | |
| push: | |
| branches: [main] # main ブランチへの push で自動実行 | |
| workflow_dispatch: # 手動実行も可 | |
| jobs: | |
| build-and-deploy: | |
| runs-on: ubuntu-latest | |
| permissions: # ←★ これを追加 | |
| contents: write # (リポジトリへの push を許可) | |
| steps: | |
| # ① リポジトリ取得 | |
| - uses: actions/checkout@v4 | |
| with: | |
| fetch-depth: 1 | |
| # ② Python + MkDocs (Material) をセットアップ | |
| - uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.x' | |
| - name: Install MkDocs | |
| run: | | |
| pip install mkdocs-material # 必要に応じてテーマ・プラグインを追加 | |
| # ③ ドキュメントをビルド | |
| - name: Build site | |
| run: mkdocs build --clean # 出力先はデフォルトで ./site | |
| # ④ gh-pages ブランチへデプロイ | |
| - name: Deploy to GitHub Pages | |
| uses: peaceiris/actions-gh-pages@v4 | |
| with: | |
| github_token: ${{ secrets.GITHUB_TOKEN }} # リポジトリ自動付与の token | |
| publish_dir: ./site # ③で生成されたディレクトリ | |
| publish_branch: gh-pages # デフォルト。好きに変更可 |