Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Slight documentation clarification #2401

Closed
nyurik opened this issue Jan 23, 2023 · 3 comments
Closed

Slight documentation clarification #2401

nyurik opened this issue Jan 23, 2023 · 3 comments
Labels
doc An issue with or an improvement to documentation. rollup A PR that has been merged with many others in a rollup.

Comments

@nyurik
Copy link

nyurik commented Jan 23, 2023

I think the first documentation line should clarify that ripgrep searches the content of the files, as oppose to the filenames that match regex (like fd).

Current description:

ripgrep is a line-oriented search tool that recursively searches the current
directory for a regex pattern.

Some ideas (not sure about the wording yet):

ripgrep recursively searches for text files whose content matches a regular expression pattern.

@BurntSushi
Copy link
Owner

I settled on this:

ripgrep (rg) recursively searches the current directory for lines matching
a regex pattern. By default, ripgrep will respect gitignore rules and
automatically skip hidden files/directories and binary files.

@BurntSushi BurntSushi added doc An issue with or an improvement to documentation. rollup A PR that has been merged with many others in a rollup. labels Nov 22, 2023
@nyurik
Copy link
Author

nyurik commented Nov 22, 2023

Do you think the current directory is needed in the description? Seems like recursively searches for lines ... is descriptive enough.

@nyurik
Copy link
Author

nyurik commented Nov 22, 2023

P.S. tbh lines is also a bit of a minor confusion - usually novice users think of files in terms of content or text. The fact that its a line search tool is more of an implementation detail (that might even be overridable with various multiline regexes?). So perhaps something like this? (sorry for bikeshading):

ripgrep (rg) recursively searches files for content matching a regex pattern.
By default, ripgrep will respect gitignore rules and automatically skip
hidden files/directories and binary files.

BurntSushi added a commit that referenced this issue Nov 25, 2023
This mimics what was written in the man page.

Closes #2401
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
doc An issue with or an improvement to documentation. rollup A PR that has been merged with many others in a rollup.
Projects
None yet
Development

No branches or pull requests

2 participants