-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcompiler.py
More file actions
25 lines (22 loc) · 825 Bytes
/
compiler.py
File metadata and controls
25 lines (22 loc) · 825 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import os
import traceback
validation = input("In order to compile TimeManager in .exe you have to install Nuitka lib. Continue? Y or enter to cancel ")
working_dir = os.getcwd()
if validation == "y" or validation == "Y":
try:
import nuitka
print("Module Nuitka already installed")
except ModuleNotFoundError:
print("Installing module Nuitka")
os.system("pip install nuitka")
pass
os.system('nuitka '
'--file-version=0.0.5.1 '
'--product-name=Time_manager '
'--enable-console '
'--standalone '
'--windows-icon-from-ico=coding.ico '
f'--output-dir="{working_dir}" '
'--remove-output main.py')
elif not validation:
print("compilation canceled")