Skip to content

Commit

Permalink
fix(plugin): fix github workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
samcyn committed Apr 1, 2024
1 parent 9cbbfdf commit 40ed8c7
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 22 deletions.
26 changes: 10 additions & 16 deletions .github/workflows/publish-npm.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Publish to npm with Yarn
name: Release

on:
push:
Expand All @@ -9,29 +9,23 @@ on:
- release

jobs:
publish:
release:
runs-on: ubuntu-latest

steps:
- name: Checkout code
- name: Checkout repository
uses: actions/checkout@v2

- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: 20.9.0
registry-url: 'https://registry.npmjs.org/'

- name: Install Yarn
run: npm install -g [email protected]

- name: Install dependencies with Yarn
run: yarn install --frozen-lockfile

- name: Run tests with Yarn
run: yarn test
- name: Install dependencies
run: npm ci

- name: Publish to npm with Yarn
if: github.event_name == 'push' && github.ref == 'refs/heads/release'
run: yarn publish --access public
- name: Release
run: npx semantic-release
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
9 changes: 3 additions & 6 deletions .github/workflows/update-main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,11 +21,8 @@ jobs:
with:
node-version: 20.9.0

- name: Install Yarn
run: npm install -g [email protected]

- name: Install dependencies with Yarn
run: yarn install --frozen-lockfile
- name: Install dependencies
run: npm ci

- name: Run tests with Yarn
run: yarn test
run: npm test

0 comments on commit 40ed8c7

Please sign in to comment.