Skip to content

Commit adaa262

Browse files
committed
macdeploy: remove existing Bitcoin-Core.dmg if present
1 parent ccb0325 commit adaa262

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

contrib/macdeploy/macdeployqtplus

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -523,6 +523,7 @@ verbose = config.verbose
523523
# ------------------------------------------------
524524

525525
app_bundle = config.app_bundle[0]
526+
appname = config.appname[0]
526527

527528
if not os.path.exists(app_bundle):
528529
sys.stderr.write("Error: Could not find app bundle \"{}\"\n".format(app_bundle))
@@ -531,13 +532,12 @@ if not os.path.exists(app_bundle):
531532
# ------------------------------------------------
532533

533534
if os.path.exists("dist"):
534-
print("+ Removing old dist folder +")
535-
535+
print("+ Removing existing dist folder +")
536536
shutil.rmtree("dist")
537537

538-
# ------------------------------------------------
539-
540-
appname = config.appname[0]
538+
if os.path.exists(appname + ".dmg"):
539+
print("+ Removing existing DMG +")
540+
os.unlink(appname + ".dmg")
541541

542542
# ------------------------------------------------
543543

0 commit comments

Comments
 (0)