tldr/pages/windows/find.md

21 lines
579 B
Markdown
Raw Normal View History

2018-06-21 13:06:00 +01:00
# find
> Find a specified string in files.
> More information: <https://learn.microsoft.com/windows-server/administration/windows-commands/find>.
2018-06-21 13:06:00 +01:00
- Find lines that contain a specified string:
`find "{{string}}" {{path\to\file_or_directory}}`
2018-06-21 13:06:00 +01:00
- Display lines that do not contain the specified string:
`find "{{string}}" {{path\to\file_or_directory}} /v`
2018-06-21 13:06:00 +01:00
- Display the count of lines that contain the specified string:
`find "{{string}}" {{path\to\file_or_directory}} /c`
2018-06-21 13:06:00 +01:00
- Display line numbers with the list of lines:
`find "{{string}}" {{path\to\file_or_directory}} /n`