Skip to content

Commit 4a9357a

Browse files
Dragan Simicgitster
authored andcommitted
grep docs: describe --recurse-submodules further and improve formatting a bit
Clarify that --recurse-submodules cannot be used together with --untracked, and improve the formatting in a couple of places, to make it visually clear that those are the commands or the names of configuration options. While there, change a couple of "<tree>" placeholders to "_<tree>_", to help with an ongoing translation improvement effort. [1] [1] https://lore.kernel.org/git/CAPig+cQc8W4JOpB+TMP=czketU1U7wcY_x9bsP5T=3-XjGLhRQ@mail.gmail.com/ Signed-off-by: Dragan Simic <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 11c821f commit 4a9357a

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

Documentation/config/grep.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@ grep.fullName::
2424
If set to true, enable `--full-name` option by default.
2525

2626
grep.fallbackToNoIndex::
27-
If set to true, fall back to git grep --no-index if git grep
27+
If set to true, fall back to `git grep --no-index` if `git grep`
2828
is executed outside of a git repository. Defaults to false.

Documentation/git-grep.txt

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -64,9 +64,9 @@ OPTIONS
6464
--recurse-submodules::
6565
Recursively search in each submodule that is active and
6666
checked out in the repository. When used in combination with the
67-
<tree> option the prefix of all submodule output will be the name of
68-
the parent project's <tree> object. This option has no effect
69-
if `--no-index` is given.
67+
_<tree>_ option the prefix of all submodule output will be the name of
68+
the parent project's _<tree>_ object. This option cannot be used together
69+
with `--untracked`, and it has no effect if `--no-index` is specified.
7070

7171
-a::
7272
--text::
@@ -178,7 +178,7 @@ providing this option will cause it to die.
178178
Use \0 as the delimiter for pathnames in the output, and print
179179
them verbatim. Without this option, pathnames with "unusual"
180180
characters are quoted as explained for the configuration
181-
variable core.quotePath (see linkgit:git-config[1]).
181+
variable `core.quotePath` (see linkgit:git-config[1]).
182182

183183
-o::
184184
--only-matching::
@@ -332,7 +332,7 @@ EXAMPLES
332332
NOTES ON THREADS
333333
----------------
334334

335-
The `--threads` option (and the grep.threads configuration) will be ignored when
335+
The `--threads` option (and the `grep.threads` configuration) will be ignored when
336336
`--open-files-in-pager` is used, forcing a single-threaded execution.
337337

338338
When grepping the object store (with `--cached` or giving tree objects), running

0 commit comments

Comments
 (0)