upload cli with smms
npm install nomi-smms-upload⚠️注意:如果没有SM.MS 账号,需要在官网注册一个账号
bash
npm i -g nomi-smms-upload
`使用
`bash
上传
nomi-smms-upload [options]帮助文档
nomi-smms-upload --help
`options 参数说明
#### config
> CLI 上传配置文件
>
> 默认值:nomi.smms.config.js使用方式:
-c, --config
`bash
nomi-smms-upload -c nomi.smms.config.js
`配置文件参数:
| 参数 | 描述 | 类型 | 默认值 |
| -----| ---- | ---- | ---- |
| token | SM.MS API Token | string | - |
配置文件示例:
`javascript
module.exports = {
token: 'xxxx'
}
`
通过SM.MS生成 API Token
!smms api token#### token
> SM.MS API Token
使用方式:
-t, --token
`bash
nomi-smms-upload --token xxx
`#### file
> 待上传本地文件路径或目录路径(相对路径)
使用方式:
-f, --file
`bash
nomi-smms-upload --file path/to/example.jpg
`#### debug
> 是否开启调试模式
使用方式:
-d, --debug
`bash
nomi-smms-upload --debug
``