Skip to content

Commit

Permalink
Remove useless argument --src (#124)
Browse files Browse the repository at this point in the history
  • Loading branch information
jsh9 authored Feb 17, 2024
1 parent 70eb3c8 commit 3a5e4b0
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 24 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
# Change Log

## [unpublished] - 2024-02-17
## [0.4.1] - 2024-02-17

- Fixed
- A bug where using double quotes in Literal type (such as `Literal["foo"]`
could produce a false positive `DOC203` violation.
- Removed useless argument `--src`

## [0.4.0] - 2024-02-08

Expand Down
22 changes: 0 additions & 22 deletions pydoclint/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,12 +42,6 @@ def validateStyleValue(
context_settings={'help_option_names': ['-h', '--help']},
help='Pydoclint, a linter for Python docstring styles',
)
@click.option(
'-s',
'--src',
type=str,
help='The source code to check',
)
@click.option(
'-q',
'--quiet',
Expand Down Expand Up @@ -273,7 +267,6 @@ def main( # noqa: C901
quiet: bool,
exclude: str,
style: str,
src: Optional[str],
paths: Tuple[str, ...],
type_hints_in_signature: str,
type_hints_in_docstring: str,
Expand Down Expand Up @@ -341,21 +334,6 @@ def main( # noqa: C901
)
ctx.exit(1)

if paths and src is not None:
click.echo(
main.get_usage(ctx)
+ "\n\n'paths' and 'src' cannot be passed simultaneously.",
err=echoAsError,
)
ctx.exit(1)

if not paths and src is None:
click.echo(
main.get_usage(ctx) + "\n\nOne of 'paths' or 'src' is required.",
err=echoAsError,
)
ctx.exit(1)

# it means users supply this option
if baseline is not None:
baselinePath = Path(baseline)
Expand Down
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[metadata]
name = pydoclint
version = 0.4.0
version = 0.4.1
description = A Python docstring linter that checks arguments, returns, yields, and raises sections
long_description = file: README.md
long_description_content_type = text/markdown
Expand Down

0 comments on commit 3a5e4b0

Please sign in to comment.