{"id":627,"date":"2010-01-06T14:57:00","date_gmt":"2010-01-06T19:57:00","guid":{"rendered":"http:\/\/appcrawler.com\/wordpress\/?p=627"},"modified":"2011-07-06T10:35:48","modified_gmt":"2011-07-06T15:35:48","slug":"delete-files-older-than-another-file","status":"publish","type":"post","link":"http:\/\/appcrawler.com\/wordpress\/2010\/01\/06\/delete-files-older-than-another-file\/","title":{"rendered":"Delete files older than another file"},"content":{"rendered":"<p>Using the find command in *nix is very useful.  You can specify that you would like to find files newer than another file, or older or newer than a certain time.  You cannot (directly) find files older than another file.  However, there is a simple step that allows you to do this.<\/p>\n<p>Simply add the negation operator (!) to the find -newer switch, and it will everything outside of what that set returns.  In other words, it returns files older than the file you pass.<\/p>\n<pre lang=\"text\" line=\"1\">\r\nfind . ! -newer your_file_timestamp_you_are_checking.txt\r\n<\/pre>\n","protected":false},"excerpt":{"rendered":"<p>Using the find command in *nix is very useful. You can specify that you would like to find files newer than another file, or older or newer than a certain time. You cannot (directly) find files older than another file.&hellip;<\/p>\n<p class=\"more-link-p\"><a class=\"more-link\" href=\"http:\/\/appcrawler.com\/wordpress\/2010\/01\/06\/delete-files-older-than-another-file\/\">Read more &rarr;<\/a><\/p>\n","protected":false},"author":2,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_mi_skip_tracking":false,"footnotes":""},"categories":[28,27],"tags":[],"_links":{"self":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/627"}],"collection":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/comments?post=627"}],"version-history":[{"count":7,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/627\/revisions"}],"predecessor-version":[{"id":630,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/posts\/627\/revisions\/630"}],"wp:attachment":[{"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/media?parent=627"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/categories?post=627"},{"taxonomy":"post_tag","embeddable":true,"href":"http:\/\/appcrawler.com\/wordpress\/wp-json\/wp\/v2\/tags?post=627"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}