deploy docs only on master branch
This commit is contained in:
parent
bb3e24260e
commit
76ca731b8e
36
.github/workflows/build-deploy-docs.yml
vendored
Normal file
36
.github/workflows/build-deploy-docs.yml
vendored
Normal file
@ -0,0 +1,36 @@
|
|||||||
|
name: Build Deploy Docs
|
||||||
|
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
branches:
|
||||||
|
- master
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-deploy-docs:
|
||||||
|
if: github.repository == 'laradock/laradock'
|
||||||
|
runs-on: ubuntu-20.04
|
||||||
|
# concurrency:
|
||||||
|
# group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
defaults:
|
||||||
|
run:
|
||||||
|
working-directory: ./DOCUMENTATION
|
||||||
|
steps:
|
||||||
|
- name: Checkout Source Code
|
||||||
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
|
- name: Setup Hugo
|
||||||
|
uses: peaceiris/actions-hugo@v2
|
||||||
|
with:
|
||||||
|
hugo-version: 'latest'
|
||||||
|
env:
|
||||||
|
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
|
||||||
|
|
||||||
|
- name: Build Hugo Site
|
||||||
|
run: hugo --minify
|
||||||
|
|
||||||
|
- name: Deploy Hugo Site to Github Pages
|
||||||
|
uses: peaceiris/actions-gh-pages@v3
|
||||||
|
with:
|
||||||
|
github_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
publish_branch: gh-pages
|
||||||
|
publish_dir: ./docs
|
29
.github/workflows/main-ci.yml
vendored
29
.github/workflows/main-ci.yml
vendored
@ -9,35 +9,6 @@ on:
|
|||||||
- cron: '0 0 * * 0'
|
- cron: '0 0 * * 0'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build-deploy-docs:
|
|
||||||
if: github.repository == 'laradock/laradock'
|
|
||||||
runs-on: ubuntu-20.04
|
|
||||||
# concurrency:
|
|
||||||
# group: ${{ github.workflow }}-${{ github.ref }}
|
|
||||||
defaults:
|
|
||||||
run:
|
|
||||||
working-directory: ./DOCUMENTATION
|
|
||||||
steps:
|
|
||||||
- name: Checkout Source Code
|
|
||||||
uses: actions/checkout@v2
|
|
||||||
|
|
||||||
- name: Setup Hugo
|
|
||||||
uses: peaceiris/actions-hugo@v2
|
|
||||||
with:
|
|
||||||
hugo-version: 'latest'
|
|
||||||
env:
|
|
||||||
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
|
|
||||||
|
|
||||||
- name: Build Hugo Site
|
|
||||||
run: hugo --minify
|
|
||||||
|
|
||||||
- name: Deploy Hugo Site to Github Pages
|
|
||||||
uses: peaceiris/actions-gh-pages@v3
|
|
||||||
with:
|
|
||||||
github_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
publish_branch: gh-pages
|
|
||||||
publish_dir: ./docs
|
|
||||||
|
|
||||||
build-php:
|
build-php:
|
||||||
# Don't trigger on schedule event when in a fork
|
# Don't trigger on schedule event when in a fork
|
||||||
if: github.event_name != 'schedule' || (github.event_name == 'schedule' && github.repository == 'laradock/laradock')
|
if: github.event_name != 'schedule' || (github.event_name == 'schedule' && github.repository == 'laradock/laradock')
|
||||||
|
Loading…
Reference in New Issue
Block a user