Skip to content
Merged
Show file tree
Hide file tree
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
7 changes: 1 addition & 6 deletions bin/generate_schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,17 +6,12 @@

import argparse
import copy
import functools
import json
import sys
from typing import Any

import yaml

make_parser = functools.partial(argparse.ArgumentParser, allow_abbrev=False)
if sys.version_info >= (3, 14):
make_parser = functools.partial(make_parser, color=True, suggest_on_error=True)
parser = make_parser()
parser = argparse.ArgumentParser(allow_abbrev=False)
parser.add_argument("--schemastore", action="store_true", help="Generate schema_store version")
args = parser.parse_args()

Expand Down
6 changes: 1 addition & 5 deletions bin/run_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@


import argparse
import functools
import os
import subprocess
import sys
Expand All @@ -14,10 +13,7 @@
else:
default_cpu_count = os.process_cpu_count() or 2

make_parser = functools.partial(argparse.ArgumentParser, allow_abbrev=False)
if sys.version_info >= (3, 14):
make_parser = functools.partial(make_parser, color=True, suggest_on_error=True)
parser = make_parser()
parser = argparse.ArgumentParser(allow_abbrev=False)
parser.add_argument(
"--run-podman", action="store_true", default=False, help="run podman tests (linux only)"
)
Expand Down
6 changes: 1 addition & 5 deletions bin/sample_build.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@


import argparse
import functools
import os
import subprocess
import sys
Expand All @@ -13,10 +12,7 @@
# move cwd to the project root
os.chdir(Path(__file__).resolve().parents[1])

make_parser = functools.partial(argparse.ArgumentParser, allow_abbrev=False)
if sys.version_info >= (3, 14):
make_parser = functools.partial(make_parser, color=True, suggest_on_error=True)
parser = make_parser(description="Runs a sample build")
parser = argparse.ArgumentParser(description="Runs a sample build", allow_abbrev=False)
parser.add_argument("project_python_path", nargs="?", default="test.test_0_basic.basic_project")

options = parser.parse_args()
Expand Down
7 changes: 2 additions & 5 deletions cibuildwheel/__main__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
import argparse
import contextlib
import dataclasses
import functools
import os
import shutil
import sys
Expand Down Expand Up @@ -80,16 +79,14 @@ def main_inner(global_options: GlobalOptions) -> None:
rather than exiting directly.
"""

make_parser = functools.partial(argparse.ArgumentParser, allow_abbrev=False)
if sys.version_info >= (3, 14):
make_parser = functools.partial(make_parser, color=True, suggest_on_error=True)
parser = make_parser(
parser = argparse.ArgumentParser(
description="Build wheels for all the platforms.",
epilog="""
Most options are supplied via environment variables or in
--config-file (pyproject.toml usually). See
https://github.com/pypa/cibuildwheel#options for info.
""",
allow_abbrev=False,
)

parser.add_argument(
Expand Down
Loading