-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #297 from equinor/sefo/feat/add-node-bump-workflow
ci: add publish workflow
- Loading branch information
Showing
2 changed files
with
48 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
name: Publish to NPM | ||
on: | ||
workflow_call: | ||
inputs: | ||
working_directory: | ||
description: "The working directory to publish from" | ||
required: false | ||
default: "." | ||
type: string | ||
package_name: | ||
description: "The name of the package to publish" | ||
required: true | ||
type: string | ||
secrets: | ||
npm_token: | ||
description: "The NPM token to use for publishing" | ||
required: true | ||
|
||
jobs: | ||
publish: | ||
permissions: | ||
contents: read | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v4 | ||
- name: Get published package version | ||
shell: bash | ||
run: | | ||
PKG_VERSION="$(npm search videx-wellog -json true | jq .[].version -r)" |