List recently modified files ordered by size
Build a paste-ready command, then review its compatibility and effects before running it.
find <path> -type f -mtime -<days> -printf '%s\t%TY-%Tm-%Td %TH:%TM\t%p\n' | sort -nr | head -<count>Complete required fields to copy the generated command.
read-onlyno known side effects Compatibility
LinuxVerified for Linux using bash, zsh syntax.
Operational knowledgereview due 2027-01-19
Requirementsfindfind must be installed and available on PATH.
Version supportfind Current supported releasesVerified for linux using bash, zsh syntax; consult compatibility notes for platform-specific differences.
Expected signals734003200 2026-07-23 08:41 /srv/backups/app.tarRepresentative successful output; values vary with the selected target and system state.
Known errorsfind: command not foundfind is missing or is not available on PATH.
Verifyfind {{path}} -type f -mtime -{{days}} -printf '%s\t%TY-%Tm-%Td %TH:%TM\t%p\n' | sort -nr | head -{{count}}The output matches the expected target and exits without an error.Rollback noteNot required: this command is read-only and does not change system state.
Command breakdown
01findCommandRuns the find stage of this one-liner.
02<path>ParameterA value supplied in the Fill parameters section.
03-typeOptionConfigures find with the -type option.
04fArgumentPasses f to find.
05-mtimeOptionConfigures find with the -mtime option.
06-<days>OptionConfigures find with the -<days> option.
07-printfOptionConfigures find with the -printf option.
08'%s\t%TY-%Tm-%Td %TH:%TM\t%p\n'ArgumentPasses '%s\t%TY-%Tm-%Td %TH:%TM\t%p\n' to find.
09|PipelinePasses the output on the left to the command on the right.
10sortCommandRuns the sort stage of this one-liner.
11-nrOptionConfigures sort with the -nr option.
12|PipelinePasses the output on the left to the command on the right.
13headCommandRuns the head stage of this one-liner.
14-<count>OptionConfigures head with the -<count> option.
This advanced community-curated one-liner combines several stages. Review every option and placeholder before running it.
Example input
find /srv -type f -mtime -2 -printf '%s\t%TY-%Tm-%Td %TH:%TM\t%p\n' | sort -nr | head -3
Example output
734003200 2026-07-23 08:41 /srv/backups/app.tar
92160000 2026-07-22 23:14 /srv/logs/api.log
Illustrative output — exact values vary by system and data.
Official sources