diff mbox series

[v3,3/4] ci: reintroduce prevention from perforce being quarantined in macOS

Message ID 20220423142559.32507-4-carenas@gmail.com (mailing list archive)
State Accepted
Commit 49af4481973d14d9cae1abb61e44f1567369cd65
Headers show
Series ci: avoid perforce/brew issues affecting macOS | expand

Commit Message

Carlo Marcelo Arenas Belón April 23, 2022, 2:25 p.m. UTC
5ed9fc3fc86 (ci: prevent `perforce` from being quarantined, 2020-02-27)
introduces this prevention for brew, but brew has been removed in a
previous commit, so reintroduce an equivalent option to avoid a possible
regression.

This doesn't affect github actions (as configure now) and is therefore
done silently to avoid any possible scary irrelevant messages.

Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
---
 ci/install-dependencies.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Eric Sunshine April 24, 2022, 6:47 a.m. UTC | #1
On Sat, Apr 23, 2022 at 10:26 AM Carlo Marcelo Arenas Belón
<carenas@gmail.com> wrote:
> 5ed9fc3fc86 (ci: prevent `perforce` from being quarantined, 2020-02-27)
> introduces this prevention for brew, but brew has been removed in a
> previous commit, so reintroduce an equivalent option to avoid a possible
> regression.
>
> This doesn't affect github actions (as configure now) and is therefore
> done silently to avoid any possible scary irrelevant messages.

s/configure/configured/

> Signed-off-by: Carlo Marcelo Arenas Belón <carenas@gmail.com>
> ---
> diff --git a/ci/install-dependencies.sh b/ci/install-dependencies.sh
> @@ -41,7 +41,8 @@ macos-latest)
>         (
>                 cd $HOME/bin
>                 wget -q "https://cdist2.perforce.com/perforce/r21.2/bin.macosx1015x86_64/helix-core-server.tgz" &&
> -               tar -xf helix-core-server.tgz
> +               tar -xf helix-core-server.tgz &&
> +               sudo xattr -d com.apple.quarantine p4 p4d 2>/dev/null || true
>         )
>         PATH="$PATH:${HOME}/bin"
>         export PATH

I don't see the point of the `|| true` since the code doesn't care
about the eventual outcome of the &&-chain. (The &&-chain itself makes
sense, though, to avoid executing commands pointlessly if an earlier
step failed.) May not be worth a reroll, though.
diff mbox series

Patch

diff --git a/ci/install-dependencies.sh b/ci/install-dependencies.sh
index 9da03350d09..46a23a33dbd 100755
--- a/ci/install-dependencies.sh
+++ b/ci/install-dependencies.sh
@@ -41,7 +41,8 @@  macos-latest)
 	(
 		cd $HOME/bin
 		wget -q "https://cdist2.perforce.com/perforce/r21.2/bin.macosx1015x86_64/helix-core-server.tgz" &&
-		tar -xf helix-core-server.tgz
+		tar -xf helix-core-server.tgz &&
+		sudo xattr -d com.apple.quarantine p4 p4d 2>/dev/null || true
 	)
 	PATH="$PATH:${HOME}/bin"
 	export PATH