0.3.10 • Published 10 months ago

@dhlx/dhlx-cli v0.3.10

Weekly downloads
-
License
MIT
Repository
github
Last release
10 months ago

dhlx-cli

一、简介

dhlx 命令行工具

二、安装

使用以下命令通过 NPM 安装:

npm install @dhlx/dhlx-cli

三、使用示例

Usage: dhlx [options] [command]

Options:
  -V, --version                output the version number
  -h, --help                   display help for command

Commands:
  create [template] [project]  创建项目
  process [options]            处理 Excel 文件
  compress [options]           Compress images
  image-size [options]         Change images size
  word-to-html [options]       Change word to html
  convert [options]            Convert image formats
  init <type>                  Copy a specific configuration file [prettier,tsconfig,jscpd,deploy,process] from the project to the current working directory
  deploy [options]             Compress specified directories and upload to server
  excel2json [options]         将 Excel 文件转换为 JSON 格式
  json2excel [options]         将  JSON 文件转换为 Excel 格式
  gh-pages [options]           部署git hub page 页面
  code-line [options]          统计代码行数
  help [command]               display help for command

四、参数

create

复制配置文件

dhlx init prettier // 代码格式化配置
dhlx init tsconfig // 代码ts配置
dhlx init deploy // 代码部署配置
dhlx init process // xlsx对比配置

批量将word转换成html

dhlx word-to-html -i ./input -o ./output

批量将pdf 转换成 html

brew install poppler
dhlx pdf2html -i./input -o./output

部署github pages 页面, 将发布新的分支到 gh-pages分支

dhlx gh-pages -i dist

统计代码行数

dhlx code-line -e .report,node_modules,idea,.git,.github,.dist --detail
参数简写类型默认值描述
--input-i<path>./指定要扫描的目录
--excludes-e<string>node_modules,.git,dist,build要排除的目录,使用逗号分隔
--extensions-t<string>.js,.ts,.jsx,.tsx,.vue,.html,.css,.scss,.mjs要统计的文件扩展名,逗号分隔
--detail-dflag-输出详细的配置信息(用于调试)
--no-empty-line-flag-排除空行统计
--no-comment-line-flag-排除注释行统计

图片格式转换与压缩

deploy命令-文件ssh上传

process命令-excel数据处理

excel与json-相互转换

五、贡献

如果您发现任何问题或有改进的建议,欢迎提交 issue 或 pull request。

六、许可证

本项目遵循 MIT License

0.3.9

10 months ago

0.3.10

10 months ago

0.1.0

1 year ago

0.3.0

1 year ago

0.2.1

1 year ago

0.2.0

1 year ago

0.3.6

1 year ago

0.2.7

1 year ago

0.3.5

1 year ago

0.2.6

1 year ago

0.3.8

10 months ago

0.3.7

10 months ago

0.3.2

1 year ago

0.2.3

1 year ago

0.3.1

1 year ago

0.3.4

1 year ago

0.2.4

1 year ago

0.0.4

2 years ago

0.0.2

2 years ago

0.0.1

2 years ago