Skip to content

Commit

Permalink
Fix issue #478: Retry create-dmg
Browse files Browse the repository at this point in the history
  • Loading branch information
openhands-agent committed Dec 10, 2024
1 parent 49969bb commit dda46cb
Showing 1 changed file with 27 additions and 0 deletions.
27 changes: 27 additions & 0 deletions scripts/create_dmg_with_retry.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#!/bin/bash

# Retry logic for create-dmg command
max_tries=10
i=0
until create-dmg \
--no-internet-enable \
--format ULFO \
--background ../packaging/macos/dmg-background.png \
--hide-extension 'Notes Better.app' \
--icon 'Notes Better.app' 180 170 \
--icon-size 160 \
--text-size 12 \
--volname Notes \
--volicon ../src/images/notes_icon.icns \
--window-size 660 400 \
--app-drop-link 480 170 \
"${{ steps.vars.outputs.file_name }}" \
'Notes Better.app'
do
if [ $i -eq $max_tries ]
then
echo 'Error: create-dmg did not succeed even after 10 tries.'
exit 1
fi
i=$((i+1))
done

0 comments on commit dda46cb

Please sign in to comment.