Last active
August 29, 2015 14:26
-
-
Save ramananbalakrishnan/89a60b116d6e72064e52 to your computer and use it in GitHub Desktop.
Find all files modified within certain dates , sort them according to time, pick certain filenames and concatenate the gzipped files
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cat `find ./ -newermt "2015-07-29 19:30" -not -newermt "2015-07-30 06:46" -type f -printf '%T@ %p\n' |\ | |
sort -k1 -n |\ | |
grep 'access.log.*.gz' |\ | |
awk '{print $2}'` > ~/outputFile.gz |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment