findmissing: Make patch creation once daily more robust

Instead of checking the time when the script is run to decide if to
create patches, store the last day of month when patches were created
in a temporary file. Create patches if the file does not exist, or if
the day in the file does not match the current day.

BUG=None
TEST=Run scripts on target

Change-Id: I5799bd56797227004724d6cb5ef442b1a5fda8c1
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/dev-util/+/2189513
Reviewed-by: Curtis Malainey <cujomalainey@chromium.org>
Reviewed-by: Guenter Roeck <groeck@chromium.org>
Commit-Queue: Guenter Roeck <groeck@chromium.org>
Tested-by: Guenter Roeck <groeck@chromium.org>
2 files changed