Skip to content

Commit af2fa8d

Browse files
committed
chore(publish): npm run build before publish
the generated dir is named as dist instead of bin
1 parent 0a364f3 commit af2fa8d

2 files changed

Lines changed: 9 additions & 4 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,7 @@ coverage
5353
# Compiled binary addons (http://nodejs.org/api/addons.html)
5454
build/Release
5555
bin
56+
dist
5657

5758
# Dependency directory
5859
# https://www.npmjs.org/doc/misc/npm-faq.html#should-i-check-my-node_modules-folder-into-git

package.json

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,16 @@
22
"name": "push.js",
33
"version": "0.0.1",
44
"description": "A compact, cross-browser solution for Javascript desktop notifications",
5-
"main": "bin/push.js",
5+
"main": "dist/push.js",
66
"scripts": {
7-
"clean": "shx rm -rf bin",
8-
"build": "shx rm -rf bin && shx mkdir -p bin && shx cp push.js bin/. && uglifyjs push.js -o bin/push.min.js",
9-
"test": "karma start"
7+
"clean": "shx rm -rf dist",
8+
"build": "shx rm -rf dist && shx mkdir -p dist && shx cp push.js dist/. && uglifyjs push.js -o dist/push.min.js",
9+
"test": "karma start",
10+
"prepublish": "npm run build"
1011
},
12+
"files": [
13+
"dist"
14+
],
1115
"repository": {
1216
"type": "git",
1317
"url": "https://github.com/Nickersoft/push.js"

0 commit comments

Comments
 (0)