forked from ElemeFE/mint-ui
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
35 lines (27 loc) · 982 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
.PHONY: dist
default: help
install:
@if [ ! -L node_modules ]; then rm -rf node_modules; fi
npm i --registry=https://registry.npm.taobao.org
./node_modules/.bin/lerna bootstrap
dev:
npm run dev
dist:
npm run dist
dist-all:
node bin/build-all.js
deploy:
npm run deploy
pub:
./node_modules/.bin/kp $(filter-out $@,$(MAKECMDGOALS))
pub-all: dist-all
./node_modules/.bin/lerna publish
help:
@echo " \033[35mmake\033[0m \033[1m命令使用说明\033[0m"
@echo " \033[35mmake install\033[0m\t\033[0m\t--- 安装依赖"
@echo " \033[35mmake dev\033[0m\t\033[0m\t--- 开发模式"
@echo " \033[35mmake dist\033[0m\t\033[0m\t--- 编译项目,生成目标文件"
@echo " \033[35mmake dist-all\033[0m\t--- 分别编译每个组件项目"
@echo " \033[35mmake deploy\033[0m\t\033[0m\t--- 部署 demo"
@echo " \033[35mmake pub\033[0m\t\033[0m\t--- 发布到 npm 上"
@echo " \033[35mmake pub-all\033[0m\t\033[0m\t--- 发布各组件到 npm 上"