33 lines
879 B
JSON
33 lines
879 B
JSON
{
|
|
"name": "find",
|
|
"section": 1,
|
|
"title": "find files",
|
|
"synopsis": ["find [PATH...] [EXPRESSION]"],
|
|
"description": "Walks directories and applies expressions (-name, -type, -print, -maxdepth, -mindepth, logical -and/-or/-not).",
|
|
"options": [],
|
|
"keywords": ["find", "directory", "walk", "search"],
|
|
"bareOsNotes": "Expression syntax is a simplified subset.",
|
|
"examples": [
|
|
{
|
|
"caption": "files by name glob",
|
|
"code": "find . -name \"*.js\""
|
|
},
|
|
{
|
|
"caption": "directories only",
|
|
"code": "find . -type d"
|
|
},
|
|
{
|
|
"caption": "max depth",
|
|
"code": "find . -maxdepth 2 -type f"
|
|
},
|
|
{
|
|
"caption": "skip top directory level (GNU-like -mindepth 2)",
|
|
"code": "find . -mindepth 2 -type f"
|
|
},
|
|
{
|
|
"caption": "OR names",
|
|
"code": "find . \\( -name \"*.c\" -o -name \"*.h\" \\)"
|
|
}
|
|
]
|
|
}
|