22# Bu Program Python-Calcutator'u derlemek için oluşturulmuştur.
33# This program was created to compile Python-Calcutator.
44
5- import os
5+ import platform , os
66import time
77
8- operating_sys = str ( input ( 'Operating System (Windows/Linux/MacOS): ' ) )
8+ operating_sys = platform . system ( )
99
10- if operating_sys == "Windows" :
10+ if operating_sys == "Windows" or operating_sys == "windows" or operating_sys == "NT" or operating_sys == "nt " :
1111 users_name = str (input ('Enter The Users Name: ' ))
1212 ProgramPath_Ws = str (input ('Version (EN/TR): ' ))
1313 debug = os .system ("cd {0}" . format (ProgramPath_Ws ))
1414 debugfile = os .system ("pyinstaller --onefile calc.py" )
15- elif operating_sys == "Linux" or operating_sys == "MacOS" :
15+
16+ elif operating_sys == "Linux" or operating_sys == "linux" or operating_sys == "MacOS" or operating_sys == "macOS" or operating_sys == "darwin" or operating_sys == "Darwin" :
1617 users_nm = str (input ('Enter The Users Name: ' ))
1718 ver_name = str (input ('Version (EN/TR): ' ))
1819 ProgramPath = str ("/home/{0}/Desktop/Python-Calcutator-main/{1}/" . format (users_nm ,ver_name ))
1920 debugPath = str (os .system ("cd /home/{0}/Desktop/Python-Calcutator-main/{1}" . format (users_nm ,ver_name )))
2021 time .sleep (2 )
21- print ("[DEBUGANDRUN]: Program Derlenmeye Hazırlanıyor ..." )
22+ print ("[DEBUGANDRUN]: The Program is Preparing to Compile ..." )
2223 time .sleep (2 )
23- print ("[DEBUGANDRUN]: Program Bilgileri Kontrol Ediliyor ..." )
24+ print ("[DEBUGANDRUN]: Checking Program Information ..." )
2425 users_list = str (list (users_nm ))
2526 ver_list = str (list (ver_name ))
2627 ProgramPath_list = str (list (ProgramPath ))
2728 debugPath_list = str (list (debugPath ))
2829 time .sleep (2 )
29- print ("[DEBUGANDRUN]: Program Bilgileri Listeleniyor ...\n {0}\n {1}\n {2}\n {3}" . format (users_list ,ver_list ,ProgramPath_list ,debugPath_list ))
30+ print ("[DEBUGANDRUN]: Program Information Listed ...\n {0}\n {1}\n {2}\n {3}" . format (users_list ,ver_list ,ProgramPath_list ,debugPath_list ))
3031 time .sleep (2 )
31- print ("[DEBUGANDRUN] Program Derleyicisi Hazırlanıyor..." )
32- global debugger ,debugger_opt ,debug_file
33- debugger = str ('pyinstaller' )
34- debugger_opt = str ('--onefile' )
35- debug_file = str ("calc.py" )
32+ print ("[DEBUGANDRUN] Program Compiler is Preparing..." )
3633 time .sleep (2 )
37- print ("[DEBUGANDRUN]: Program Derleniyor..." )
38- dbg = os .system ("{0} {1} {2}" . format (debugger ,debugger_opt ,debug_file ))
34+ print ("[DEBUGANDRUN]: Compiling the Program..." )
35+ dbg = os .system ("pyinstaller --onefile calc.py" )
36+ dbg
3937 time .sleep (2 )
40- print ("[DEBUGANDRUN]: Derleme İşlemi Bitmiştir..." )
38+ print ("[DEBUGANDRUN]: Compilation Process is Completed..." )
39+
4140else :
4241 print ("Invalid Operating System...!" )
0 commit comments