From: Daniele Varrazzo Date: Fri, 12 Apr 2024 22:05:00 +0000 (+0200) Subject: refactor(async-to-sync): rename --convert-all option to --all X-Git-Tag: 3.2.0~46^2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F787%2Fhead;p=thirdparty%2Fpsycopg.git refactor(async-to-sync): rename --convert-all option to --all --- diff --git a/.github/workflows/lint.yml b/.github/workflows/lint.yml index 64c42ede0..dc15839ad 100644 --- a/.github/workflows/lint.yml +++ b/.github/workflows/lint.yml @@ -37,7 +37,7 @@ jobs: run: mypy - name: Check for sync/async inconsistencies - run: ./tools/async_to_sync.py --check -B + run: ./tools/async_to_sync.py --check --all - name: Check spelling run: codespell diff --git a/tools/async_to_sync.py b/tools/async_to_sync.py index c748bbe9c..989181a08 100755 --- a/tools/async_to_sync.py +++ b/tools/async_to_sync.py @@ -85,7 +85,7 @@ def main() -> int: PYVER, ) - if not opt.convert_all: + if not opt.all: inputs, outputs = [], [] for fpin in opt.inputs: fpout = fpin.parent / fpin.name.replace("_async", "") @@ -95,7 +95,7 @@ def main() -> int: inputs.append(fpin) outputs.append(fpout) if not outputs: - logger.warning("all output files are up to date, nothing to do") + logger.info("all output files are up to date, nothing to do") return 0 else: @@ -561,7 +561,7 @@ def parse_cmdline() -> Namespace: ) parser.add_argument( "-B", - "--convert-all", + "--all", action="store_true", help="process specified files without checking last modification times", )