CI: retry a failed brew update too, not just brew install

Also, make sure an eventual failure ends up returning a failure code so
the job stops.
This commit is contained in:
Dan Fandrich 2023-03-10 09:53:09 -08:00
parent af369db4d3
commit dc141a37d3
2 changed files with 3 additions and 3 deletions

View File

@ -210,7 +210,7 @@ macos_task:
pkginstall_script:
- echo libtool autoconf automake pkg-config ${install_packages} | xargs -Ix -n1 echo brew '"x"' > /tmp/Brewfile
- brew update && for i in 1 2 3; do brew bundle install --no-lock --file /tmp/Brewfile && break || sleep 1; done
- "for i in 1 2 3; do brew update && brew bundle install --no-lock --file /tmp/Brewfile && break || { echo Error: wait to try again; sleep 10; false; } done"
- sudo -H python3 -m pip install --upgrade pip
- sudo -H python3 -m pip install impacket
configure_script:

View File

@ -96,7 +96,7 @@ jobs:
# Run this command with retries because of spurious failures seen
# while running the tests, for example
# https://github.com/curl/curl/runs/4095721123?check_suite_focus=true
- run: brew update && for i in 1 2 3; do brew bundle install --no-lock --file /tmp/Brewfile && break || sleep 1; done
- run: "for i in 1 2 3; do brew update && brew bundle install --no-lock --file /tmp/Brewfile && break || { echo Error: wait to try again; sleep 10; false; } done"
name: 'brew install'
- run: python3 -m pip install impacket
@ -155,7 +155,7 @@ jobs:
- run: echo libtool autoconf automake pkg-config ${{ matrix.build.install }} | xargs -Ix -n1 echo brew '"x"' > /tmp/Brewfile
name: 'brew bundle'
- run: brew update && brew bundle install --no-lock --file /tmp/Brewfile
- run: "for i in 1 2 3; do brew update && brew bundle install --no-lock --file /tmp/Brewfile && break || { echo Error: wait to try again; sleep 10; false; } done"
name: 'brew install'
- run: python3 -m pip install impacket