grep: update translations (#12962)

This commit is contained in:
spageektti
2024-06-13 19:08:33 +02:00
committed by GitHub
parent d387240363
commit 122cdf8cd2
11 changed files with 60 additions and 60 deletions

View File

@@ -9,15 +9,15 @@
- 在文件中精确地查找字符串(禁用正则表达式):
`grep --fixed-strings "{{字符串}}" {{路径/到/文件}}`
`grep {{-F|--fixed-strings}} "{{字符串}}" {{路径/到/文件}}`
- 在指定目录下的所有文件中递归地查找模式,显示匹配的行号并忽略二进制文件:
`grep --recursive --line-number --binary-files={{without-match}} "{{模式字符串}}" {{路径/到/目录}}`
`grep {{-r|--recursive}} {{-n|--line-number}} --binary-files={{without-match}} "{{模式字符串}}" {{路径/到/目录}}`
- 使用大小写不敏感的扩展正则表达式(支持 `?``+``{}``()``|`
`grep --extended-regexp --ignore-case "{{模式字符串}}" {{路径/到/文件}}`
`grep {{-E|--extended-regexp}} {{-i|--ignore-case}} "{{模式字符串}}" {{路径/到/文件}}`
- 在每个匹配前后、之前或之后打印 3 行上下文:
@@ -25,12 +25,12 @@
- 以带有颜色的方式,打印每个匹配的文件名和行号:
`grep --with-filename --line-number --color=always "{{模式字符串}}" {{路径/到/文件}}`
`grep {{-H|--with-filename}} {{-n|--line-number}} --color=always "{{模式字符串}}" {{路径/到/文件}}`
- 只打印文件中与模式匹配的行:
`grep --only-matching "{{模式字符串}}" {{路径/到/文件}}`
`grep {{-o|--only-matching}} "{{模式字符串}}" {{路径/到/文件}}`
-`stdin`(标准输入)中查找与模式不匹配的行:
`cat {{路径/到/文件}} | grep --invert-match "{{模式字符串}}"`
`cat {{路径/到/文件}} | grep {{-v|--invert-match}} "{{模式字符串}}"`