Skip to content

Commit

Permalink
ci: split publish and version
Browse files Browse the repository at this point in the history
  • Loading branch information
EdouardDem committed Nov 20, 2023
1 parent 631c8a3 commit c7da4b4
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 4 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Lerna publish

on:
push:
branches: [ main ]

jobs:
publish:
runs-on: ubuntu-latest
if: "contains(github.event.head_commit.message, 'chore(release): bump version')"
steps:
- uses: actions/checkout@v2
with:
token: ${{ secrets.GH_TOKEN }}
- name: Use Node.js 18.x
uses: actions/setup-node@v3
with:
node-version: '18.x'
registry-url: 'https://registry.npmjs.org/'
- run: npm ci
- run: npm run build
- run: npm run lerna publish from-package
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Lerna version & publish
name: Lerna version

on:
push:
Expand Down Expand Up @@ -26,6 +26,3 @@ jobs:
- run: npm run test
- run: npm run build
- run: npm run lerna version
- run: npm run lerna publish from-package
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

0 comments on commit c7da4b4

Please sign in to comment.