setup build process

This commit is contained in:
Samuel Walker 2024-06-20 17:47:35 -06:00
parent aa4f38972e
commit b1c0d9662d
3 changed files with 9 additions and 1 deletions

View File

@ -12,6 +12,12 @@ import time
import math import math
def resource_path(relative_path):
try:
base_path = sys._MEIPASS
except Exception:
base_path = os.path.abspath(".")
return os.path.join(base_path, relative_path)
def perform_installation(instance_name, prism_command, prism_instance_path, pack): def perform_installation(instance_name, prism_command, prism_instance_path, pack):
try: try:

View File

@ -73,7 +73,7 @@ def main():
#Title image #Title image
titleimage = Image.open("Title.png") titleimage = Image.open(Backend.resource_path("Title.png"))
titlelabel = CTkLabel(master=app, text="", image=CTkImage(titleimage, size=(400, 150))) titlelabel = CTkLabel(master=app, text="", image=CTkImage(titleimage, size=(400, 150)))
titlelabel.pack(expand=True, padx=0, pady=0) titlelabel.pack(expand=True, padx=0, pady=0)

2
build-linux.sh Executable file
View File

@ -0,0 +1,2 @@
pyinstaller --onefile Main.py --hidden-import='PIL._tkinter_finder' --add-data "Title.png:." --windowed
pyinstaller --onefile Upload.py --hidden-import='PIL._tkinter_finder' --windowed