mirror of
https://github.com/HIllya51/LunaTranslator.git
synced 2025-01-01 10:04:12 +08:00
auto
This commit is contained in:
parent
161498b8ec
commit
1748e5f8a1
@ -1,5 +1,6 @@
|
|||||||
import modulefinder, shutil, os, sys, pefile
|
import modulefinder, shutil, os, sys, pefile
|
||||||
import builtins, platform
|
import builtins, platform
|
||||||
|
import sys
|
||||||
|
|
||||||
pyversion = platform.python_version()
|
pyversion = platform.python_version()
|
||||||
pyversion2 = "".join(pyversion.split(".")[:2])
|
pyversion2 = "".join(pyversion.split(".")[:2])
|
||||||
@ -12,11 +13,7 @@ if x86:
|
|||||||
launch = r"..\plugins\builds\_x86"
|
launch = r"..\plugins\builds\_x86"
|
||||||
baddll = "DLL64"
|
baddll = "DLL64"
|
||||||
gooddll = "DLL32"
|
gooddll = "DLL32"
|
||||||
py37Path = f"C:\\hostedtoolcache\\windows\\Python\\{pyversion}\\x86\\python.exe"
|
|
||||||
py37Pathlocal = (
|
|
||||||
os.environ["LOCALAPPDATA"]
|
|
||||||
+ rf"\Programs\Python\Python{pyversion2}-32\python.exe"
|
|
||||||
)
|
|
||||||
webviewappendix = r"Lib\site-packages\webviewpy\platform\win32\x86\webview.dll"
|
webviewappendix = r"Lib\site-packages\webviewpy\platform\win32\x86\webview.dll"
|
||||||
else:
|
else:
|
||||||
baddll = "DLL32"
|
baddll = "DLL32"
|
||||||
@ -26,14 +23,10 @@ else:
|
|||||||
targetdir = r"..\build\LunaTranslator"
|
targetdir = r"..\build\LunaTranslator"
|
||||||
downlevel = r"C:\Windows\system32\downlevel"
|
downlevel = r"C:\Windows\system32\downlevel"
|
||||||
|
|
||||||
py37Path = f"C:\\hostedtoolcache\\windows\\Python\\{pyversion}\\x64\\python.exe"
|
|
||||||
py37Pathlocal = (
|
|
||||||
os.environ["LOCALAPPDATA"] + rf"\Programs\Python\Python{pyversion2}\python.exe"
|
|
||||||
)
|
|
||||||
webviewappendix = r"Lib\site-packages\webviewpy\platform\win32\x64\webview.dll"
|
webviewappendix = r"Lib\site-packages\webviewpy\platform\win32\x64\webview.dll"
|
||||||
if os.path.exists(py37Path) == False:
|
|
||||||
py37Path = py37Pathlocal
|
py37Path = sys.executable
|
||||||
py37Path = os.path.dirname(py37Path)
|
print(py37Path)
|
||||||
py37Pathwebview = os.path.join(py37Path, webviewappendix)
|
py37Pathwebview = os.path.join(py37Path, webviewappendix)
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user