diff --git a/.circleci/config.yml b/.circleci/config.yml index 17e50a66..40288c2d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -104,7 +104,7 @@ jobs: command: | cd ~\project\desktop poetry run python .\setup-freeze.py build - poetry run python .\script\build-windows.py cleanup-build + poetry run python .\scripts\build-windows.py cleanup-build - run: name: Compress command: | @@ -152,7 +152,7 @@ jobs: command: | cd ~\project\desktop C:\Python-32bit\Scripts\poetry run python .\setup-freeze.py build - C:\Python-32bit\Scripts\poetry run python .\package\windows.py cleanup-build + C:\Python-32bit\Scripts\poetry run python .\scripts\build-windows.py cleanup-build - run: name: Compress command: | @@ -201,7 +201,7 @@ jobs: command: | cd ~/project/desktop poetry run python ./setup-freeze.py bdist_mac - poetry run python ./install/build-macos.py cleanup-build + poetry run python ./scripts/build-macos.py cleanup-build - run: name: Compress command: zip -r ~/onionshare-macos.zip ~/project/desktop/build/OnionShare.app diff --git a/desktop/scripts/build-macos.py b/desktop/scripts/build-macos.py index 4d4c02e0..f9586de0 100644 --- a/desktop/scripts/build-macos.py +++ b/desktop/scripts/build-macos.py @@ -142,9 +142,14 @@ def cleanup_build(): shutil.rmtree( f"{app_path}/Contents/MacOS/lib/PySide2/Qt/lib/{framework}.framework" ) + print( + f"Deleted: {app_path}/Contents/MacOS/lib/PySide2/Qt/lib/{framework}.framework" + ) try: os.remove(f"{app_path}/Contents/MacOS/lib/PySide2/{framework}.abi3.so") os.remove(f"{app_path}/Contents/MacOS/lib/PySide2/{framework}.pyi") + print(f"Deleted: {app_path}/Contents/MacOS/lib/PySide2/{framework}.abi3.so") + print(f"Deleted: {app_path}/Contents/MacOS/lib/PySide2/{framework}.pyi") except FileNotFoundError: pass @@ -219,10 +224,12 @@ def cleanup_build(): f"{app_path}/Contents/Resources/lib/PySide2/rcc", f"{app_path}/Contents/Resources/lib/PySide2/uic", ]: - if os.path.isdir(filename): - shutil.rmtree(filename) - elif os.path.isfile(filename): + if os.path.isfile(filename) or os.path.islink(filename): os.remove(filename) + print(f"Deleted: {filename}") + elif os.path.isdir(filename): + shutil.rmtree(filename) + print(f"Deleted: {filename}") else: print(f"Cannot delete, filename not found: {filename}")