MCPcopy Create free account
hub / github.com/cjrd/self-supervised-pretraining / write_version_py

Function write_version_py

OpenSelfSup/setup.py:67–78  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

65
66
67def write_version_py():
68 content = """# GENERATED VERSION FILE
69# TIME: {}
70
71__version__ = '{}'
72short_version = '{}'
73"""
74 sha = get_hash()
75 VERSION = SHORT_VERSION + '+' + sha
76
77 with open(version_file, 'w') as f:
78 f.write(content.format(time.asctime(), VERSION, SHORT_VERSION))
79
80
81def get_version():

Callers 1

setup.pyFile · 0.85

Calls 2

get_hashFunction · 0.85
writeMethod · 0.45

Tested by

no test coverage detected