Skip to content

docs: clarify repeated --exclude usage#18469

Open
liruiluo wants to merge 3 commits intoastral-sh:mainfrom
liruiluo:docs/pip-freeze-exclude-example
Open

docs: clarify repeated --exclude usage#18469
liruiluo wants to merge 3 commits intoastral-sh:mainfrom
liruiluo:docs/pip-freeze-exclude-example

Conversation

@liruiluo
Copy link
Copy Markdown
Contributor

Summary

  • document that --exclude can be repeated
  • add a concrete uv pip freeze --exclude ... --exclude ... example
  • mirror the repeated-flag wording in the CLI help text

Fixes #18429.

Comment on lines +2545 to +2546
/// Exclude the specified package(s) from the output. Repeat to exclude
/// multiple packages, e.g., `--exclude pip --exclude setuptools`.
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should not be included on the first line.

Suggested change
/// Exclude the specified package(s) from the output. Repeat to exclude
/// multiple packages, e.g., `--exclude pip --exclude setuptools`.
/// Exclude the specified package(s) from the output.
///
/// Repeat to exclude multiple packages, e.g., `--exclude pip --exclude setuptools`.

Does the "Repeat to..." language match other options where we say a flag can be repeated? I don't think so?

$ uv pip freeze
```

Repeat `--exclude` to omit multiple packages from the output:
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It doesn't make sense to say "Repeat --exclude" here before introducing --exclude. Just explain --exclude can be used to omit packages.

I'm on the fence about explaining this functionality at all in this document, it doesn't seem valuable enough.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Documentation: Add example of multiple exclusions for uv pip freeze --exclude

2 participants