Skip to content

Commit

Permalink
fix: build code into dist and only publish that to NPM
Browse files Browse the repository at this point in the history
  • Loading branch information
adrians5j committed Jun 27, 2024
1 parent 4d2f56b commit e000042
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 3 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ jobs:
- name: Checkout
uses: actions/checkout@v4

- name: Build
uses: yarn build

- name: Semantic Release
uses: cycjimmy/semantic-release-action@v4
env:
Expand Down
6 changes: 4 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
{
"name": "wts-client",
"version": "2.0.0",
"description": "",
"description": "Webiny Telemetry Service (WTS) client library.",
"scripts": {
"build": "rm -rf dist && cp -rf src dist && cp package.json dist/package.json",
"test:web": "node __tests__/web.test.js",
"test:node": "node __tests__/node.test.js",
"test:admin": "node __tests__/admin.test.js"
Expand All @@ -24,5 +25,6 @@
},
"devDependencies": {
"prettier": "^2.3.0"
}
},
"packageManager": "[email protected]+sha1.4ba7fc5c6e704fce2066ecbfb0b0d8976fe62447"
}
8 changes: 7 additions & 1 deletion release.config.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,11 @@
* @type {import('semantic-release').GlobalConfig}
*/
export default {
branches: ["v2"]
branches: ["v2"],
plugins: [
"@semantic-release/commit-analyzer",
"@semantic-release/release-notes-generator",
["@semantic-release/npm", {"pkgRoot": "./dist"}],
"@semantic-release/github"
]
};

0 comments on commit e000042

Please sign in to comment.