Refer to --archs by its real name in help, error message and docs (#2992)
Refer to --archs by its real name in help, error and docs The --only help text, the --only/--archs conflict error and the platform section of docs/options.md all name a --arch option. The parser defines --archs and sets allow_abbrev=False, so --arch is rejected as an unrecognized argument. Co-authored-by: hxperl <[email protected]>
This commit is contained in:
@@ -153,7 +153,7 @@ def main_inner(global_options: GlobalOptions) -> None:
|
||||
metavar="IDENTIFIER",
|
||||
help="""
|
||||
Force a single wheel build when given an identifier. Overrides
|
||||
CIBW_BUILD/CIBW_SKIP. --platform and --arch cannot be specified
|
||||
CIBW_BUILD/CIBW_SKIP. --platform and --archs cannot be specified
|
||||
if this is given.
|
||||
""",
|
||||
)
|
||||
@@ -323,7 +323,7 @@ def _compute_platform(args: CommandLineArguments) -> PlatformName:
|
||||
msg = "--platform cannot be specified with --only, it is computed from --only"
|
||||
raise errors.ConfigurationError(msg)
|
||||
if args.only and args.archs is not None:
|
||||
msg = "--arch cannot be specified with --only, it is computed from --only"
|
||||
msg = "--archs cannot be specified with --only, it is computed from --only"
|
||||
raise errors.ConfigurationError(msg)
|
||||
|
||||
if platform_option_value not in PLATFORMS | {"auto"}:
|
||||
|
||||
+1
-1
@@ -43,7 +43,7 @@ This option can also be set using the [command-line option](#command-line) `--pl
|
||||
This is even more convenient if you store your cibuildwheel config in [`pyproject.toml`](configuration.md#configuration-file).
|
||||
|
||||
You can also run a single identifier with `--only <identifier>`. This will
|
||||
not require `--platform` or `--arch`, and will override any build/skip
|
||||
not require `--platform` or `--archs`, and will override any build/skip
|
||||
configuration.
|
||||
|
||||
### `build`, `skip` {: #build-skip toml env-var }
|
||||
|
||||
Reference in New Issue
Block a user