npm package: @qcloud-apaas/component-tools-cli
Description: 腾讯云千帆ApaaS组件脚手架Cli
Latest version: 2.0.6

@qcloud-apaas/component-tools-cli
=================================

腾讯云千帆ApaaS组件脚手架Cli

[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io)
[![Version](https://img.shields.io/npm/v/@qcloud-apaas/component-tools-cli.svg)](https://npmjs.org/package/@qcloud-apaas/component-tools-cli)
[![Downloads/week](https://img.shields.io/npm/dw/@qcloud-apaas/component-tools-cli.svg)](https://npmjs.org/package/@qcloud-apaas/component-tools-cli)
[![License](https://img.shields.io/npm/l/@qcloud-apaas/component-tools-cli.svg)](https://github.com/firesnow3676/component-tools-cli/blob/master/package.json)

<!-- toc -->
* [Usage](#usage)
* [Commands](#commands)
<!-- tocstop -->
# Usage
<!-- usage -->
```sh-session
$ npm install -g @qcloud-apaas/component-tools-cli
$ qcomponent COMMAND
running command...
$ qcomponent (-v|--version|version)
@qcloud-apaas/component-tools-cli/2.0.6 darwin-x64 node-v14.16.1
$ qcomponent --help [COMMAND]
USAGE
  $ qcomponent COMMAND
...
```
<!-- usagestop -->
# Commands
<!-- commands -->
* [`qcomponent build`](#qcomponent-build)
* [`qcomponent config [CONFIGKEY] [CONFIGVALUE]`](#qcomponent-config-configkey-configvalue)
* [`qcomponent create [KEY]`](#qcomponent-create-key)
* [`qcomponent help [COMMAND]`](#qcomponent-help-command)
* [`qcomponent mkcert`](#qcomponent-mkcert)
* [`qcomponent publish`](#qcomponent-publish)
* [`qcomponent release [RELEASETYPE]`](#qcomponent-release-releasetype)
* [`qcomponent release-version [RELEASETYPE]`](#qcomponent-release-version-releasetype)
* [`qcomponent start`](#qcomponent-start)
* [`qcomponent tpk`](#qcomponent-tpk)

## `qcomponent build`

构建组件

```
USAGE
  $ qcomponent build

OPTIONS
  -c, --config=config  自定义webpack配置
  -h, --help           查看帮助
  -m, --min            是否压缩包体积
  -t, --tpk            是否生成tpk包

EXAMPLES
  $ qcomponent build
  $ qcomponent build -c ./webpack.config.js
  $ qcomponent build --tpk --min
  $ qcomponent build -t -m
```

_See code: [src/commands/build.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/build.ts)_

## `qcomponent config [CONFIGKEY] [CONFIGVALUE]`

修改环境配置，可设置secretId和secretKey

```
USAGE
  $ qcomponent config [CONFIGKEY] [CONFIGVALUE]

OPTIONS
  -h, --help  查看帮助

EXAMPLES
  $ qcomponent config secretId <secretId>
  $ qcomponent config secretKey <secretKey>
```

_See code: [src/commands/config.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/config.ts)_

## `qcomponent create [KEY]`

生成代码

```
USAGE
  $ qcomponent create [KEY]

ARGUMENTS
  KEY  由组件的标识转化为kebab-case。运行之后，会在当前路径创建名为组件名的文件名。

OPTIONS
  -h, --help  查看帮助

EXAMPLE
  $ qcomponent create <key>
```

_See code: [src/commands/create.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/create.ts)_

## `qcomponent help [COMMAND]`

display help for qcomponent

```
USAGE
  $ qcomponent help [COMMAND]

ARGUMENTS
  COMMAND  command to show help for

OPTIONS
  --all  see all commands in CLI
```

_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v3.2.2/src/commands/help.ts)_

## `qcomponent mkcert`

生成ssl根证书，信任证书可通过浏览器HTTPS安全性校验

```
USAGE
  $ qcomponent mkcert

OPTIONS
  -h, --help  查看帮助

EXAMPLE
  $ qcomponent mkcert
```

_See code: [src/commands/mkcert.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/mkcert.ts)_

## `qcomponent publish`

仅发布组件

```
USAGE
  $ qcomponent publish

OPTIONS
  -h, --help  查看帮助

EXAMPLE
  $ qcomponent publish
```

_See code: [src/commands/publish.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/publish.ts)_

## `qcomponent release [RELEASETYPE]`

一键发布组件，构建、设置版本、发布。release = build + release-version + publish

```
USAGE
  $ qcomponent release [RELEASETYPE]

ARGUMENTS
  RELEASETYPE  发布版本类型 patch|minor|major, 参考semver版本规范

OPTIONS
  -h, --help  查看帮助

EXAMPLE
  $ qcomponent release
```

_See code: [src/commands/release.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/release.ts)_

## `qcomponent release-version [RELEASETYPE]`

设置版本

```
USAGE
  $ qcomponent release-version [RELEASETYPE]

ARGUMENTS
  RELEASETYPE  发布版本类型 patch|minor|major, 参考semver版本规范

OPTIONS
  -h, --help  查看帮助

EXAMPLE
  $ qcomponent release-version <releaseType>
```

_See code: [src/commands/release-version.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/release-version.ts)_

## `qcomponent start`

运行组件，启动开发

```
USAGE
  $ qcomponent start

OPTIONS
  -c, --config=config  webpack配置
  -h, --help           查看帮助
  -p, --port=port      运行端口

EXAMPLES
  $ qcomponent start
  $ qcomponent start -p 8080
  $ qcomponent start -c ./webpack.config.js
```

_See code: [src/commands/start.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/start.ts)_

## `qcomponent tpk`

打包组件，同时生成tpk格式组件包。等同于qcomponent build --tpk

```
USAGE
  $ qcomponent tpk

OPTIONS
  -c, --config=config  自定义webpack配置
  -h, --help           查看帮助
  -m, --min            是否压缩包体积

EXAMPLE
  $ qcomponent tpk
```

_See code: [src/commands/tpk.ts](https://github.com/qcloud-apaas/component-tools-cli/blob/v2.0.6/src/commands/tpk.ts)_
<!-- commandsstop -->