Skip to content

Commit 7773b4d

Browse files
committed
fix!: remove old -p/--parseable option
Removes outdated -p/--parseable option which duplicated `--format=pep8` more generic option.
1 parent 6f3c2eb commit 7773b4d

File tree

11 files changed

+5
-26
lines changed

11 files changed

+5
-26
lines changed

.ansible-lint

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,6 @@ exclude_paths:
1313
- .cache/ # implicit unless exclude_paths is defined in config
1414
- test/fixtures/formatting-before/
1515
- test/fixtures/formatting-prettier/
16-
# parseable: true
1716
# quiet: true
1817
# strict: true
1918
# verbosity: 1

.config/dictionary.txt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,6 @@ nodeps
4646
nomatchestest
4747
nxos
4848
octals
49-
parseable
5049
pathex
5150
pbrun
5251
pfexec

.pre-commit-config.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ repos:
3030
hooks:
3131
- id: check-useless-excludes
3232
- repo: https://github.com/astral-sh/uv-pre-commit
33-
rev: 0.9.18
33+
rev: 0.9.21
3434
hooks:
3535
- id: uv-sync
3636
- id: uv-lock
@@ -146,7 +146,7 @@ repos:
146146
entry: yamllint --strict
147147

148148
- repo: https://github.com/tombi-toml/tombi-pre-commit
149-
rev: v0.7.11
149+
rev: v0.7.14
150150
hooks:
151151
- id: tombi-format
152152
alias: toml

docs/usage.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ Ansible-lint prints output on both `stdout` and `stderr`.
1717
- `stderr` displays logging and free-form messages like statistics.
1818

1919
Most `ansible-lint` examples use pep8 as the output format (`-p`) which is
20-
machine parseable.
20+
machine parsable.
2121

2222
Ansible-lint also print errors using their [annotation] format when it detects
2323
the `GITHUB_ACTIONS=true` and `GITHUB_WORKFLOW=...` variables.

src/ansiblelint/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -372,7 +372,7 @@ def choose_formatter_factory(
372372
r = formatters.CodeclimateJSONFormatter
373373
elif options_list.format == "sarif":
374374
r = formatters.SarifFormatter
375-
elif options_list.parseable or options_list.format == "pep8":
375+
elif options_list.format == "pep8":
376376
r = formatters.ParseableFormatter
377377
return r
378378

src/ansiblelint/cli.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -317,14 +317,6 @@ def get_cli_parser() -> argparse.ArgumentParser:
317317
choices=PROFILES.keys(),
318318
help="Specify which rules profile to be used.",
319319
)
320-
parser.add_argument(
321-
"-p",
322-
"--parseable",
323-
dest="parseable",
324-
default=False,
325-
action="store_true",
326-
help="parseable output, same as '-f pep8'",
327-
)
328320
parser.add_argument(
329321
"--project-dir",
330322
dest="project_dir",
@@ -493,7 +485,6 @@ def merge_config(file_config: dict[Any, Any], cli_config: Options) -> Options:
493485
"""Combine the file config with the CLI args."""
494486
bools = (
495487
"display_relative_path",
496-
"parseable",
497488
"quiet",
498489
"strict",
499490
"use_default_rules",

src/ansiblelint/config.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,6 @@ class Options: # pylint: disable=too-many-instance-attributes
143143
list_tags: bool = False
144144
write_list: list[str] = field(default_factory=list)
145145
write_exclude_list: list[str] = field(default_factory=list)
146-
parseable: bool = False
147146
quiet: bool = False
148147
rulesdirs: list[Path] = field(default_factory=list)
149148
skip_list: list[str] = field(default_factory=list)

src/ansiblelint/schemas/ansible-lint-config.json

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,6 @@
101101
"title": "Only Builtins Allow Modules",
102102
"type": "array"
103103
},
104-
"parseable": {
105-
"default": true,
106-
"title": "Parseable",
107-
"type": "boolean"
108-
},
109104
"profile": {
110105
"enum": [
111106
"min",

test/fixtures/parseable.yml

Lines changed: 0 additions & 3 deletions
This file was deleted.

test/test_cli.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ def fixture_base_arguments() -> list[str]:
2323
@pytest.mark.parametrize(
2424
("args", "config_path"),
2525
(
26-
pytest.param(["-p"], "test/fixtures/parseable.yml", id="1"),
2726
pytest.param(["-q"], "test/fixtures/quiet.yml", id="2"),
2827
pytest.param(
2928
["-r", "test/fixtures/rules/"],

0 commit comments

Comments
 (0)