-
Notifications
You must be signed in to change notification settings - Fork 19
/
Makefile
40 lines (31 loc) · 780 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
BIN = ./node_modules/.bin
uglify = ./node_modules/.bin/uglifyjs
install link:
@npm $@
lint:
./node_modules/.bin/eslint ./index.jsx
patch: lint
make prepublish
@$(call release,patch)
minor: lint
make prepublish
@$(call release,minor)
major: lint
make prepublish
@$(call release,major)
jsx:
@$(call lint)
./node_modules/.bin/babel index.jsx > index.js
@$(uglify) index.js -o dist/react-stickydiv.min.js --source-map dist/react-stickydiv.min.js.map -p 5 -c drop_console -m
cp dist/react-stickydiv.min.js index.js
prepublish:
make jsx
@(sh bin/authors)
git commit -am "`npm view . version`" --allow-empty
publish:
git commit -am "`npm view . version`" --allow-empty
git push --tags origin HEAD:master
npm publish
define release
npm version $(1)
endef