mirror of
https://github.com/mbirth/tcl_ota_check.git
synced 2024-11-10 06:16:46 +00:00
Output old version for FULL search as well. Also: colour coding - OTA=yellow, FULL=cyan
This commit is contained in:
parent
9d8e0e8ff1
commit
99b4fd7912
6
tclcheck_allfull.py
Executable file → Normal file
6
tclcheck_allfull.py
Executable file → Normal file
@ -41,7 +41,11 @@ for prd, variant in prds.items():
|
|||||||
curef, fv, tv, fw_id, fileid, fn, fsize, fhash = fc.parse_check(check_xml)
|
curef, fv, tv, fw_id, fileid, fn, fsize, fhash = fc.parse_check(check_xml)
|
||||||
txt_tv = tv
|
txt_tv = tv
|
||||||
if tv != lastver:
|
if tv != lastver:
|
||||||
txt_tv = tcllib.ANSI_CYAN + txt_tv + tcllib.ANSI_RESET + " (OTA: {})".format(variant["last_ota"])
|
txt_tv = "{} (old: {} / OTA: {})".format(
|
||||||
|
tcllib.ANSI_CYAN + txt_tv + tcllib.ANSI_RESET,
|
||||||
|
tcllib.ANSI_CYAN_DARK + variant["last_full"] + tcllib.ANSI_RESET,
|
||||||
|
variant["last_ota"]
|
||||||
|
)
|
||||||
print("{}: {} {} ({})".format(prd, txt_tv, fhash, model))
|
print("{}: {} {} ({})".format(prd, txt_tv, fhash, model))
|
||||||
except RequestException as e:
|
except RequestException as e:
|
||||||
print("{}: {}".format(prd, str(e)))
|
print("{}: {}".format(prd, str(e)))
|
||||||
|
2
tclcheck_allota.py
Executable file → Normal file
2
tclcheck_allota.py
Executable file → Normal file
@ -48,7 +48,7 @@ for prd, variant in prds.items():
|
|||||||
fc.fv = lastver
|
fc.fv = lastver
|
||||||
check_xml = fc.do_check(max_tries=20)
|
check_xml = fc.do_check(max_tries=20)
|
||||||
curef, fv, tv, fw_id, fileid, fn, fsize, fhash = fc.parse_check(check_xml)
|
curef, fv, tv, fw_id, fileid, fn, fsize, fhash = fc.parse_check(check_xml)
|
||||||
versioninfo = tcllib.ANSI_CYAN_DARK + fv + tcllib.ANSI_RESET + " ⇨ " + tcllib.ANSI_CYAN + tv + tcllib.ANSI_RESET + " (FULL: {})".format(variant["last_full"])
|
versioninfo = tcllib.ANSI_YELLOW_DARK + fv + tcllib.ANSI_RESET + " ⇨ " + tcllib.ANSI_YELLOW + tv + tcllib.ANSI_RESET + " (FULL: {})".format(variant["last_full"])
|
||||||
print("{}: {} {} ({})".format(prd, versioninfo, fhash, model))
|
print("{}: {} {} ({})".format(prd, versioninfo, fhash, model))
|
||||||
except RequestException as e:
|
except RequestException as e:
|
||||||
print("{} ({}): {}".format(prd, lastver, str(e)))
|
print("{} ({}): {}".format(prd, lastver, str(e)))
|
||||||
|
Loading…
Reference in New Issue
Block a user