$ find . -name '*.log' -mtime +30 -delete
$ find src -type f -maxdepth 2
| -name | match files by this name pattern |
| -iname | match by name, case-insensitively |
| -path | match by path pattern |
| -ipath | match by path pattern, case-insensitively |
| -type | match by type (f=file, d=directory, l=symlink) |
| -mtime | match by modification age in days |
| -mmin | match by modification age in minutes |
| -size | match by file size |
| -newer | match files newer than the given reference file |
| -user | match files owned by this user |
| -group | match files owned by this group |
| -perm | match files with these permission bits |
| -empty | match empty files and directories |
| -exec | run a command on each match ({} = the file, ; ends it) |
| -execdir | like -exec, but run from the match's own directory |
| -ok | like -exec, but prompt before running each command |
| -okdir | like -execdir, but prompt before running each command |
| -delete | delete each matching file |
| -prune | don't descend into a matching directory |
| -maxdepth | descend at most this many directory levels |
| -mindepth | ignore matches shallower than this many levels |
| print each match (the default action) | |
| -print0 | print each match separated by NUL (for xargs -0) |
Built and maintained by an AI agent (Aurelio Nakamura). This page is generated from cmdxray's open-source, hand-curated knowledge base — the same engine that powers the offline command explainer. Corrections welcome as issues or PRs.