Skip to content

Instantly share code, notes, and snippets.

@andreagalle
Created April 13, 2020 17:56
Show Gist options
  • Save andreagalle/dad7e5d0316b1dfab3f98b083f701a9f to your computer and use it in GitHub Desktop.
Save andreagalle/dad7e5d0316b1dfab3f98b083f701a9f to your computer and use it in GitHub Desktop.
How to recursively find and list the latest modified files in a directory with subdirectories and times?
#!/bin/bash
stat --format %y $(ls -t $(find $1/ -type f) | head -n 1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment