If you use GNU find
, you can specify absolute dates as follows:
find . -name '*.pdf' -newermt 2012-01-31 ! -newermt 2012-02-29 | wc -l
The -newermt
option will find files that have been changed more recently than absolute time.
If you are not using GNU, you can use touch
to create two files with the appropriate timestamps and search for your PDF files as follows:
touch -t 201201312359 oldest
See the GNU documentation for more details.
source share