Skip to content
This repository was archived by the owner on May 23, 2021. It is now read-only.

Commit 0de7092

Browse files
committed
Improve publishing
- Exclude unnecessary files from the package. - We only want the preinstall script to run locally, not when it's installed as a dependency. - Run the build and test before publishing just to make sure that the package really is good to go before it gets uploaded.
1 parent a0790a2 commit 0de7092

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

.npmignore

+10-5
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,20 @@
1+
*.tgz
2+
.dockerignore
3+
.eslintrc.yaml
14
.gitignore
5+
.gitmodules
6+
.prettierrc.yaml
27
.travis.yml
38
.vscode
9+
build
10+
example
411
lib
5-
yarn-error.log
12+
node.patch
613
node_modules
14+
out/patches
715
scripts
816
src
917
test
10-
node.patch
1118
tsconfig.json
19+
yarn-error.log
1220
yarn.lock
13-
example
14-
build
15-
*.tgz

package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
{
22
"name": "@coder/nbin",
3-
"version": "1.2.5",
3+
"version": "1.2.6",
44
"description": "Fast and robust node.js binary compiler.",
55
"main": "out/api/index.js",
66
"scripts": {
7-
"preinstall": "./scripts/preinstall.bash",
7+
"prepublish": "./scripts/preinstall.bash",
8+
"prepublishOnly": "yarn build && yarn test",
89
"test": "mocha",
910
"coverage": "nyc mocha",
1011
"lint": "eslint src test typings --ext .ts",

0 commit comments

Comments
 (0)