Skip to content

Commit

Permalink
fix: simplify workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
Filipe Correa committed Mar 6, 2023
1 parent cdedaf9 commit cdde025
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 35 deletions.
26 changes: 0 additions & 26 deletions .github/workflows/publish.yml

This file was deleted.

29 changes: 26 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,39 @@ name: Release

on:
push:
branches:
- master
branches: [ main ]

jobs:
release:
name: GitHub
name: Release
runs-on: ubuntu-latest
outputs:
created: ${{ steps.release.outputs.release_created }}
steps:
- name: Release
uses: google-github-actions/release-please-action@v3
id: release
with:
release-type: node
package-name: react-image-hotspots
publish:
name: Publish
needs: release
runs-on: ubuntu-latest
if: ${{ needs.release.outputs.created }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '16.x'
registry-url: 'https://registry.npmjs.org'
- name: Install modules
run: npm ci
- name: Build
run: npm run build --if-present
- name: Publish
run: npm publish
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
7 changes: 1 addition & 6 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,7 @@ name: Test

on:
push:
branches:
- '*'
paths-ignore:
- 'docs/**'
- 'LICENSE'
- 'README.md'
branches: [ '*' ]

jobs:
test:
Expand Down

0 comments on commit cdde025

Please sign in to comment.