From d66434f37c354eed88bfd84918ad65369422fd19 Mon Sep 17 00:00:00 2001 From: duffbeer2000 Date: Mon, 3 Feb 2020 14:45:52 +0100 Subject: [PATCH] Update fw_downloads.py --- fw_downloads.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/fw_downloads.py b/fw_downloads.py index d263324..ba3fbbf 100644 --- a/fw_downloads.py +++ b/fw_downloads.py @@ -13,7 +13,7 @@ except ImportError: from urllib import urlretrieve now = datetime.datetime.now() -print ('%d - Downloadscript started' % now.strftime("%Y-%m-%d %H:%M")) +print ('%s - Downloadscript started' % now.strftime("%Y-%m-%d %H:%M")) f = urlopen("http://fw.ota.homesmart.ikea.net/feed/version_info.json") data = f.read() @@ -38,7 +38,7 @@ for i in arr: urlretrieve(url, path) print(path) else: - print('%s already exists' % fname) + print('%s - %s already exists' % (now.strftime("%Y-%m-%d %H:%M"), fname)) """ @@ -68,8 +68,8 @@ for x in range(len(productlist)): file = open(path, "wb") file.write(firmwarecontent) file.close() - print(path) + print('%s - %s downloaded' % (now.strftime("%Y-%m-%d %H:%M"), path)) else: - print('%s already exists' % fname) + print('%s - %s already exists' % (now.strftime("%Y-%m-%d %H:%M"), fname)) -print ('%d - Downloadscript stopped' % now.strftime("%Y-%m-%d %H:%M")) \ No newline at end of file +print ('%s - Downloadscript stopped' % now.strftime("%Y-%m-%d %H:%M")) \ No newline at end of file