Skip to content

Commit

Permalink
Add --fail option to curl
Browse files Browse the repository at this point in the history
  • Loading branch information
harendra-kumar committed Dec 16, 2023
1 parent 1a257b3 commit 5e9b956
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
8 changes: 4 additions & 4 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,8 +79,9 @@ preinstall: &preinstall
# required for https/cache save and restore
apt-get install -y ca-certificates
# NOTE: depends on specific debian version in the deb line below
# For ghc and cabal-install packages from haskell.org
# Alternative way of installing ghc and cabal, directly from
# haskell.org instead of using ghcup. NOTE: this is for Debian
# only and is debian release specific.
# gnupg is required for apt-key to work
#apt-get install -y gnupg
#apt-key adv --keyserver keyserver.ubuntu.com --recv-keys BA3CBA3FFE22B574
Expand Down Expand Up @@ -115,9 +116,8 @@ preinstall: &preinstall
then
die "PACKCHECK_GITHUB_COMMIT is not specified."
fi
CURL=$(which curl)
PACKCHECK_URL=${PACKCHECK_GITHUB_URL}/${PACKCHECK_GITHUB_COMMIT}/packcheck.sh
$CURL -sL -o "$PACKCHECK" $PACKCHECK_URL
curl --fail -sL -o "$PACKCHECK" $PACKCHECK_URL || exit 1
chmod +x $PACKCHECK
elif test ! -x "$PACKCHECK"
then
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/packcheck.yml
Original file line number Diff line number Diff line change
Expand Up @@ -151,9 +151,8 @@ jobs:
then
die "PACKCHECK_GITHUB_COMMIT is not specified."
fi
CURL=$(which curl)
PACKCHECK_URL=${PACKCHECK_GITHUB_URL}/${PACKCHECK_GITHUB_COMMIT}/packcheck.sh
$CURL -sL -o "$PACKCHECK" $PACKCHECK_URL
curl --fail -sL -o "$PACKCHECK" $PACKCHECK_URL || exit 1
chmod +x $PACKCHECK
elif test ! -x "$PACKCHECK"
then
Expand Down

0 comments on commit 5e9b956

Please sign in to comment.