I am writing a script that will look in a custom reports directory, copy it to a working folder, along with the data files that it will look at, runs the report, zips the newly created files, and uploads them to another server.
The problem that I'm running into is that I don't know what the newly created files will be called at all (nor file extensions). I was wondering if there was a way of zipping or finding out what the newly created files were (as compared to before the report was run and after).
I would look at the timestamps and just move the newest files somewhere to zip them, however the reports that are being run could potentially create multiple files at different times (such as a phone report file first, then after, a data report file).
Any ideas on how I could accomplish this?