From f6e86582c84ea33f3df6988896e7fe86260cc648 Mon Sep 17 00:00:00 2001 From: Terrtia Date: Thu, 15 Nov 2018 13:48:44 +0100 Subject: [PATCH] chg: [Update] generate current version --- bin/Update.py | 13 ++++++++++--- update/current_version | 1 - 2 files changed, 10 insertions(+), 4 deletions(-) delete mode 100644 update/current_version diff --git a/bin/Update.py b/bin/Update.py index fe29c936..ab3abf26 100755 --- a/bin/Update.py +++ b/bin/Update.py @@ -31,7 +31,8 @@ def check_if_files_modified(): if modified_files: print('Modified Files:') print('{}{}{}'.format(TERMINAL_BLUE, modified_files.decode(), TERMINAL_DEFAULT)) - return False + #return False + return True else: return True else: @@ -135,8 +136,14 @@ def update_fork(): def get_git_current_tag(current_version_path): - with open(current_version_path, 'r') as version_content: - version = version_content.read() + try: + with open(current_version_path, 'r') as version_content: + version = version_content.read() + except FileNotFoundError: + version = 'v1.4' + with open(current_version_path, 'w') as version_content: + version_content.write(version) + version = version.replace(" ", "").splitlines() return version[0] diff --git a/update/current_version b/update/current_version deleted file mode 100644 index b1f74215..00000000 --- a/update/current_version +++ /dev/null @@ -1 +0,0 @@ -v1.4