Skip to content

Instantly share code, notes, and snippets.

@velenux
Created January 4, 2011 20:23
Show Gist options
  • Save velenux/765352 to your computer and use it in GitHub Desktop.
Save velenux/765352 to your computer and use it in GitHub Desktop.
how many files today?
#!/bin/bash
FILES=$(find -name '*.ref' -ctime -1 -print)
N_FILES=$(find -name '*.ref' -ctime -1 -print|wc -l)
TIMESTAMP=$(stat -c %y $FILES | cut -b1-16 | sort | tail -n1)
DATE=${TIMESTAMP:0:10}
TIME=${TIMESTAMP:11:16}
echo $DATE $N_FILES files last $TIME
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment