diff --git a/source/get_github_file.py b/source/get_github_file.py index df61bbd..0268474 100644 --- a/source/get_github_file.py +++ b/source/get_github_file.py @@ -1,10 +1,14 @@ import requests +import os + root = "https://raw.githubusercontent.com/Faraphel/MKWF-Install/master/" def get_github_file(self, file): try: + if os.path.exists(file): return 1 dl = requests.get(root+file, allow_redirects=True, stream=True) + if dl.status_code == 200: # if page is found with open(file, "wb") as file: chunk_size = 4096