Skip to content

Commit

Permalink
fix: append -sdk to version for sdk releases
Browse files Browse the repository at this point in the history
  • Loading branch information
ayushmanchhabra committed Oct 26, 2023
1 parent 812e92a commit 08785c3
Show file tree
Hide file tree
Showing 4 changed files with 22 additions and 4 deletions.
7 changes: 7 additions & 0 deletions .github/sdk.mjs
@@ -0,0 +1,7 @@
import { writeFile } from 'node:fs/promises';

import nodeManifest from '../package.json' assert { type: 'json' };

nodeManifest.version = nodeManifest.version + '-sdk';

await writeFile('./package.json', JSON.stringify(nodeManifest, null, 2));
13 changes: 12 additions & 1 deletion .github/workflows/cd.yml
Expand Up @@ -5,16 +5,27 @@ on:
branches: [ master ]

jobs:
npm:
sdk:
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4.1.1
- name: Setup Node
uses: actions/setup-node@v4.0.0
with:
node-version: 20
- name: Prepare for SDK release
run: node .github/sdk.mjs
- name: Publish sdk tag to npm
uses: JS-DevTools/npm-publish@v3.0.1
with:
token: ${{ secrets.NPM_TOKEN }}
tag: sdk
normal:
runs-on: ubuntu-22.04
steps:
- name: Checkout repository
uses: actions/checkout@v4.1.1
- name: Publish latest tag to npm
uses: JS-DevTools/npm-publish@v3.0.1
with:
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
@@ -1,6 +1,6 @@
{
"name": "nw",
"version": "0.81.0-2",
"version": "0.81.0-3",
"description": "A installer for nw.js",
"repository": {
"type": "git",
Expand Down

0 comments on commit 08785c3

Please sign in to comment.