demo-cli-ccc-aaa

1.0.0 • Public • Published

demo-cli

演示步骤

$ npm i
$ npm link

演示完成后取消本地软链

$ npm unlink

已有的功能

Usage: demo < commander [options] | <options> >

Options:
  -V, --version                    output the version number
  -d, --debug                      output extra debugging
  -m, --mall                       small pizza size
  -p, --pizza-type <type>          flavour of pizza
  -h, --help                       display help for command

Commands:
  fs-extra|fs [options] <operate>  fs operation
  server [options]                 serve operation
  spawn [options]                  spawn operation
  help [command]                   display help for command

可执行的例子

复制相对路径:
$ demo fs copy -f ./node_modules -t ./node_modules_copy
复制绝对路径
$ demo fs copy -f ./node_modules -t d:/workspace/demo-cli/node_modules_copy2
删除
$ demo fs remove -f ./node_modules_copy
移动
$ demo fs move -f ./yanshi-from/remove -t ./yanshi/to
读文件
$ demo fs readFile -f ./.prettierrc
写文件
$ demo fs writeFile -f ./fswritefile.txt -fd write-successfull

启动一个服务,指定端口号
$ demo server --server-port 7865

用spawn执行一个node脚本
$ demo spawn -fp index.js

Readme

Keywords

none

Package Sidebar

Install

npm i demo-cli-ccc-aaa

Weekly Downloads

2

Version

1.0.0

License

ISC

Unpacked Size

10.1 kB

Total Files

23

Last publish

Collaborators

  • njr