allow running the script without the target in the current directory

This commit is contained in:
2024-09-08 08:30:23 -05:00
parent 54d3333eff
commit 7d6dfe962d

View File

@@ -1,11 +1,11 @@
import subprocess
import sys
from os.path import join
from os.path import join, basename
import os
app_bundle = sys.argv[1]
app_binary = join(app_bundle, 'Contents/MacOS', app_bundle.split(".")[0])
app_binary = join(app_bundle, 'Contents/MacOS', basename(app_bundle).split(".")[0])
app_frameworks = join(app_bundle, 'Contents/Frameworks')
binaries = [app_binary] + [join(app_frameworks, library) for library in os.listdir(app_frameworks)]