Skip to content

Commit

Permalink
chore: separate deploy from publish
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinchappell committed Nov 21, 2024
1 parent acc877a commit 3f9b182
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 8 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
name: Deploy

on:
release:
types: [created]

jobs:
build:
env:
GH_TOKEN: ${{ secrets.GH_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GH_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
CI: true
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
cache: 'npm'
node-version: 23
- name: Install dependencies
run: npm install
- name: Test
run: npm test
- name: Build
if: success()
run: npm run build
if: success()
- name: Deploy - https://draggable.github.io/formeo/
if: success()
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GH_TOKEN }}
publish_dir: ./dist/demo

8 changes: 0 additions & 8 deletions .github/workflows/publish.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,11 +30,3 @@ jobs:
- name: Publish
if: success()
run: npx semantic-release
- run: npm run build
if: success()
- name: Deploy - https://draggable.github.io/formeo/
if: success()
uses: peaceiris/actions-gh-pages@v4
with:
github_token: ${{ secrets.GH_TOKEN }}
publish_dir: ./dist/demo

0 comments on commit 3f9b182

Please sign in to comment.