File: deploy-docs.yaml

package info (click to toggle)
pyocd 0.37.0-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 355,132 kB
  • sloc: xml: 3,682,260; python: 61,563; ansic: 112; makefile: 87; asm: 25; sh: 14
file content (39 lines) | stat: -rw-r--r-- 931 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
name: Deploy docs

# Only run when docs are modified on the main branch.
on:
  push:
    branches:
      - main
    paths:
      - 'docs/**'

jobs:
  deploy:
    runs-on: ubuntu-latest
    environment: docs-deployment
    steps:
      - name: Checkout
        uses: actions/checkout@v3
        with:
          repository: 'pyocd/pyocd-website-source'
          token: ${{ secrets.DEPLOY_TOKEN }}
          submodules: true

      - name: Configure user
        run: |
            git config --global user.email "pyocd-bot-noreply@pyocd.io"
            git config --global user.name "pyocd-bot"

      - name: Update pyocd submodule
        run: |
          cd pyocd
          git fetch origin
          git switch --detach ${{ github.event.after }}

      - name: Commit and push
        run: |
          git add pyocd
          git commit -m "submodule: pyocd: sync to commit ${{ github.event.after }}"
          git push origin