Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v3.0.3-rc.0 #60

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions .github/workflows/nodejs-setup.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Node.js Setup and Test
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Refactor into a shared file so we can be sure the checks are always run.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

smart!

on:
workflow_call:
inputs:
node_version:
required: true
type: string
npm_tag:
required: false
type: string
npm_token:
required: true
type: string

jobs:
setup-and-publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: ${{ inputs.node_version }}
- run: npm install
- run: npm test
- uses: JS-DevTools/npm-publish@v1
with:
token: ${{ inputs.npm_token }}
access: public
tag: ${{ inputs.npm_tag }}

11 changes: 11 additions & 0 deletions .github/workflows/publish-rc.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Publish RC to NPM
on:
workflow_dispatch:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

☝️ and this lets us trigger from UI ✅


jobs:
publish:
uses: ./.github/workflows/nodejs-setup.yml
with:
node_version: '18.x'
npm_tag: rc
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

npm tag goes here; end-users need to explicitly select this tag and it won't "accidentally" be treated as a dependency.

npm_token: ${{ secrets.NPM_TOKEN }}
16 changes: 4 additions & 12 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,15 +5,7 @@ on:

jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
with:
node-version: '18.x'
- run: npm install
- run: npm test
- uses: JS-DevTools/npm-publish@v1
with:
token: ${{ secrets.NPM_TOKEN }}
access: public
uses: ./.github/workflows/nodejs-setup.yml
with:
node_version: '18.x'
npm_token: ${{ secrets.NPM_TOKEN }}
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@eppo/node-server-sdk",
"version": "3.0.2",
"version": "3.0.3-rc.0",
"description": "Eppo node server SDK",
"main": "dist/index.js",
"files": [
Expand Down Expand Up @@ -59,4 +59,4 @@
"node": ">=18.x",
"yarn": "1.x"
}
}
}
Loading