Skip to content

Commit

Permalink
build: use release instead of tags to trigger a build
Browse files Browse the repository at this point in the history
  • Loading branch information
Ronald Jerez committed Jan 11, 2024
1 parent ffdb206 commit d95b11d
Show file tree
Hide file tree
Showing 4 changed files with 31 additions and 55 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/documentation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Publish docs pages

on:
registry_package:
types: [published]

jobs:
docs:
name: Publish docs
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: 16
- name: Get branch name
id: find_branch
shell: bash
run: echo "branch=$(git branch --contains ${GITHUB_REF} | xargs)" >> $GITHUB_OUTPUT
- name: Install
run: npm ci
- name: Build docs
run: npm run build:docs
- name: Deploy github pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
destination_dir: ${{ steps.find_branch.outputs.branch == 'master' && 'latest' || steps.find_branch.outputs.branch }}

27 changes: 0 additions & 27 deletions .github/workflows/gh-pages-beta.yml

This file was deleted.

27 changes: 0 additions & 27 deletions .github/workflows/gh-pages-latest.yml

This file was deleted.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
"scripts": {
"prebuild": "rm -rf ./dist",
"build": "run-p type-check build:plugin build:docs",
"build:docs": "storybook build",
"build:docs": "storybook build -o build",
"build:plugin": "vite build",
"lint": "eslint . --ext .vue,.js,.cjs,.ts --fix && npm run prettier",
"lint:ci": "eslint . --ext .vue,.js,.cjs,.ts && npm run prettier:ci",
Expand Down

0 comments on commit d95b11d

Please sign in to comment.