MCPcopy Index your code
hub / github.com/cipheras/cipherginx / checkUpdate

Function checkUpdate

cipherginx.py:77–87  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

75 LEVEL = args.level
76
77def checkUpdate():
78 try:
79 logging.info('checking for updates')
80 resp = requests.get('https://api.github.com/repos/cipheras/cipherginx/releases').json()
81 version = resp[0]['tag_name']
82 release_name = resp[0]['name']
83 if version != VERSION:
84 print(BLUE+'['+GREEN+'+'+BLUE+'] Update available...'+BLINK+GREEN+version+' ['+release_name+']'+RESET)
85 except Exception as e:
86 logging.warning(RED + 'failed to get update info')
87 logging.debug(e, exc_info=True)
88
89def injectHeaders(oreq_header, url, post_body_len, path):
90 str_req_header = str(oreq_header)

Callers 1

cipherginx.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected