()
| 65 | |
| 66 | |
| 67 | def write_version_py(): |
| 68 | content = """# GENERATED VERSION FILE |
| 69 | # TIME: {} |
| 70 | |
| 71 | __version__ = '{}' |
| 72 | short_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 | |
| 81 | def get_version(): |