1
0
mirror of https://github.com/Unleash/unleash.git synced 2024-10-18 20:09:08 +02:00
unleash.unleash/.github/workflows/build_doc_prs.yaml
Gastón Fournier eb259a3783
chore: Doc only should skip build (#4820)
## About the changes
This fakes the build on docs-only PRs to be able to have a green build.
Touching a doc to validate it works
2023-09-25 09:12:03 +02:00

35 lines
1.0 KiB
YAML

name: PR -> Build Docs
on:
pull_request:
paths:
- website/**
jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build docs
env:
UNLEASH_FEEDBACK_TARGET_URL: ${{ secrets.DOCS_FEEDBACK_TARGET_URL }}
UNLEASH_PROXY_CLIENT_KEY: ${{ secrets.UNLEASH_PROXY_CLIENT_KEY_DEVELOPMENT }}
UNLEASH_PROXY_URL: ${{ secrets.UNLEASH_PROXY_URL_DEVELOPMENT }}
run: |
# Build the site
cd website && yarn
# give better error messages when the build fails (refer to website/readme.md#troubleshooting)
echo "Removing references to chalk in node_modules/@docusaurus/core/lib/client/serverEntry.js"
sed -i 's/chalk\(\w\|\.\)\+//g' node_modules/@docusaurus/core/lib/client/serverEntry.js
echo "Chalk removed"
yarn build
build:
runs-on: ubuntu-latest
name: build
strategy:
matrix:
node-version: [18.x]
steps:
- run: echo "Fake build step for docs only PRs"