mirror of
https://github.com/danieldemus/deconz_fw_downloader.git
synced 2025-01-10 15:12:00 +01:00
Update fw_downloads.py
This commit is contained in:
parent
f383142aa7
commit
d66434f37c
@ -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"))
|
||||
print ('%s - Downloadscript stopped' % now.strftime("%Y-%m-%d %H:%M"))
|
Loading…
Reference in New Issue
Block a user