Skip to content
name: "Build from alpha version and deploy docs to staging"
on:
workflow_dispatch:
push:
branches:
- master
jobs:
release:
name: "Build"
if: github.repository == 'daisyui/daisyui.github.io'
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "latest"
# registry-url: https://registry.npmjs.org
- name: Install dependencies
run: npm install
- name: build package
run: npm run build
- name: Install document website dependencies
run: cd src/docs && npm install
- name: Install latest daisyUI version
run: cd src/docs && npm i daisyui@alpha
- name: get new data from API
run: cd src/docs && npm run get-files
- name: Build document website
run: cd src/docs && npm run build
- name: Deploy docs to github pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./src/docs/build
cname: ${{ secrets.CNAME }}