Installation
npm install cm-vcli -g
or
git clone https://github.com/Michael-lzg/cm-cli.git
cd cm-cli && npm install
npm link
Usage
Open your terminal and type cm -h
, you'll see the help infomation below:
Usage: cm <command>
Options:
-V, --version output the version number
-h, --help output usage information
Commands:
add add a new template
delete delete a template
list List the templateList
init init a project
cm add
This command would help you to add a new template to the templates.json
, which will be used by cm
to init projects.
$ cm add
? ่ฏท่พๅ
ฅๆจกๆฟๅ็งฐ admin
? ่ฏท่พๅ
ฅๆจกๆฟๅฐๅ https://github.com/Michael-lzg/vue-ant-template.git
โ Add a template successfully!
The latest templateList is:
โโโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ name โ url โ
โโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ app โ https://github.com/Michael-lzg/vue-cli4-vant.git โ
โโโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ admin โ https://github.com/Michael-lzg/vue-ant-template.git โ
โโโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
cm delete
To delete a template, you could use this command:
$ cm delete
? ่ฏท่พๅ
ฅ่ฆๅ ้ค็ๆจกๆฟๅ็งฐ admin
? ่ฏท่พๅ
ฅ่ฆๅ ้ค็ๆจกๆฟๅ็งฐ admin
โ Deleted successfully!
The latest templateList is:
โโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ name โ url โ
โโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ app โ https://github.com/Michael-lzg/vue-cli4-vant.git โ
โโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
cm list
This command will shows you the templates list.
$ cm list
โโโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ name โ url โ
โโโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโค
โ app โ https://github.com/Michael-lzg/vue-cli4-vant.git โ
โโโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
cm init
You can init a templates use this command
cm init app project