Run docs build without deploy on PRs
This commit is contained in:
parent
56f46ae85c
commit
2ed1738ee9
12
.github/workflows/docs-publish.yml
vendored
12
.github/workflows/docs-publish.yml
vendored
@ -4,6 +4,7 @@ on:
|
|||||||
push:
|
push:
|
||||||
tags: [ 'v*.*.*' ]
|
tags: [ 'v*.*.*' ]
|
||||||
branches: ['main']
|
branches: ['main']
|
||||||
|
pull_request:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
permissions:
|
permissions:
|
||||||
@ -40,11 +41,14 @@ jobs:
|
|||||||
git checkout gh-pages
|
git checkout gh-pages
|
||||||
git pull origin gh-pages
|
git pull origin gh-pages
|
||||||
git checkout main
|
git checkout main
|
||||||
- name: Mike Deploy for Main
|
- name: Docs Deploy for Main
|
||||||
if: github.ref == 'refs/heads/main'
|
if: github.event_name != 'pull_request' && github.ref == 'refs/heads/main'
|
||||||
run: MKINSIDERS=true mike deploy --update --push ${{github.ref_name}}
|
run: MKINSIDERS=true mike deploy --update --push ${{github.ref_name}}
|
||||||
- name: Mike Deploy for Tags
|
- name: Docs Deploy for Tags
|
||||||
if: github.ref != 'refs/heads/main'
|
if: github.event_name != 'pull_request' && github.ref != 'refs/heads/main'
|
||||||
run: MKINSIDERS=true mike deploy --update --push ${{github.ref_name}} latest
|
run: MKINSIDERS=true mike deploy --update --push ${{github.ref_name}} latest
|
||||||
|
- name: Docs Test Build
|
||||||
|
if: github.event_name == 'pull_request'
|
||||||
|
run: MKINSIDERS=true mkdocs build
|
||||||
env:
|
env:
|
||||||
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
GH_TOKEN: ${{ secrets.GH_TOKEN }}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user