Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: correct usage of cli-flags #2205

Merged
merged 1 commit into from
Dec 7, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions packages/webpack-cli/lib/utils/cli-flags.js
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ const builtInFlags = [
// For configs
{
name: 'config',
usage: '--config <path to webpack configuration file>',
usage: '--config <path-to-config> | --config <path-to-config> --config <path-to-config>',
alias: 'c',
type: String,
multiple: true,
Expand All @@ -98,7 +98,7 @@ const builtInFlags = [
},
{
name: 'config-name',
usage: '--config-name <name of config>',
usage: '--config-name <name-of-config> | --config-name <name-of-config> --config-name <name-of-config>',
type: String,
multiple: true,
description: 'Name of the configuration to use',
Expand All @@ -114,7 +114,7 @@ const builtInFlags = [
// Complex configs
{
name: 'env',
usage: '--env',
usage: '--env <variable> | --env <variable> --env <variable=value>',
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah I think we should also mention that we support nested flags here, var1.var2.var3=value, will PR

/cc @alexander-akait

type: String,
multipleType: true,
description: 'Environment passed to the configuration when it is a function',
Expand Down Expand Up @@ -189,23 +189,23 @@ const builtInFlags = [
// For webpack@4
{
name: 'entry',
usage: '--entry <path to entry file> | --entry <path> --entry <path>',
usage: '--entry <path-to-entry-file> | --entry <path> --entry <path>',
type: String,
multiple: true,
description: 'The entry point(s) of your application e.g. ./src/main.js',
link: 'https://webpack.js.org/concepts/#entry',
},
{
name: 'output-path',
usage: '--output-path <path to output directory>',
usage: '--output-path <path-to-output-directory>',
alias: 'o',
type: String,
description: 'Output location of the file generated by webpack e.g. ./dist/',
link: 'https://webpack.js.org/configuration/output/#outputpath',
},
{
name: 'target',
usage: '--target <value>',
usage: '--target <value> | --target <value> --target <value>',
alias: 't',
type: String,
multiple: cli !== undefined,
Expand Down