Skip to content

Instantly share code, notes, and snippets.

@jimschubert
Last active May 8, 2016 14:55
Embed
What would you like to do?
A bash function to display recently changed files recursively below the current directory
#!/bin/env bash
# Display recently changed files recursively below the current directory
# recent [minutes]
# minutes: The number of minutes to display. Default 5.
#
# Credit to find usage goes to
# F. Hauri (http://superuser.com/users/178656/f-hauri)
# see: http://superuser.com/a/621727/60571
function recent {
local mins="-$((${1:-5}+0))"
find . -type f -mmin $mins -print0 | xargs -0 /bin/ls -ltr
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment