Skip to content

Commit 2545b00

Browse files
author
Philipp Karlsson
committed
fixing pipeline
1 parent d652a70 commit 2545b00

File tree

1 file changed

+11
-4
lines changed

1 file changed

+11
-4
lines changed

.github/workflows/release-package.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,9 @@ on:
55
branches:
66
- "main"
77
release:
8-
type: [ created ]
8+
types: [ created ]
9+
schedule:
10+
- cron: '0 6 * * 1' # At 06:00 on Monday
911

1012
jobs:
1113
build:
@@ -14,7 +16,7 @@ jobs:
1416
- uses: actions/checkout@v3
1517
- uses: actions/setup-node@v3
1618
with:
17-
node-version: 'v19.1.0'
19+
node-version: '19.1.0'
1820
npm-version: '9.4.2'
1921
- name: npm install library
2022
working-directory: ./library
@@ -33,6 +35,7 @@ jobs:
3335
run: npm run build
3436

3537
- name: deploy Showcase to Github Pages
38+
if: ${{ github.event_name == 'release' }}
3639
uses: JamesIves/[email protected]
3740
with:
3841
branch: docs
@@ -50,7 +53,7 @@ jobs:
5053
- uses: actions/checkout@v3
5154
- uses: actions/setup-node@v3
5255
with:
53-
node-version: '19.x'
56+
node-version: '19.1.0'
5457
registry-url: 'https://registry.npmjs.org'
5558

5659
- name: Get release version
@@ -60,8 +63,12 @@ jobs:
6063
SHORT_VERSION=${FULL_VERSION:1}
6164
echo shortVersion=${SHORT_VERSION} >> $GITHUB_OUTPUT
6265
66+
- name: Update release version
67+
working-directory: ./library
68+
run: npm version ${{ steps.release.outputs.shortVersion }}
69+
6370
- name: Publish to npmjs
6471
working-directory: ./library
65-
run: npm publish --access public --tag ${{ steps.release.outputs.shortVersion }}
72+
run: npm publish --access public
6673
env:
6774
NODE_AUTH_TOKEN: ${{secrets.NPM_PUBLISH_TOKEN}}

0 commit comments

Comments
 (0)