Back to tools

Command explainer

Paste a command line to see what each part does: pipes, options, arguments, redirections…

  • A pipe |: find → xargs; each command’s output is the next one’s input
findSearch for files by name, type and more Reference
  • .
    Start looking here: . (and every directory below)
  • -name
    Match the file name; quote wildcards
  • "*.log"
    The file name pattern: "*.log" (quoted so the command does the matching, not the shell)
  • -mtime
    By modification time, e.g. -7 for the last 7 days
  • +7
    modified more than 7 days ago
| output goes to the next command
xargsBuild command lines from standard input Reference

Reads items from standard input and runs this command with them as arguments:

rmRemove files or directories Reference
  • -f
    Force: never prompt, ignore missing files

Try these:

The explanations come from this site’s command reference (204 common commands and their most used options). Commands and options it does not cover are marked; man has the full story. Nothing is run: the line is only read.