Skip to content

Commit

Permalink
use the CI variable
Browse files Browse the repository at this point in the history
  • Loading branch information
ozgurakgun committed Mar 26, 2024
1 parent 6fcd278 commit e831009
Showing 1 changed file with 17 additions and 7 deletions.
24 changes: 17 additions & 7 deletions etc/build/silent-wrapper.sh
Original file line number Diff line number Diff line change
@@ -1,13 +1,15 @@
#!/bin/bash

# set -o errexit
# set -o nounset
set -o errexit
set -o nounset

if [ $# -ne 1 ]; then
echo "Only provide a single argument, the path to a bash script."
exit 1
fi

export CI=${CI:-false}

echo "Running $1"

PID=$$
Expand All @@ -24,11 +26,19 @@ else
echo " Exit code: ${EXITCODE}"
echo " Outputs saved to: make-solvers-${PID}.stdout and make-solvers-${PID}.stderr"
echo ""
echo "stdout was:"
cat make-solvers-${PID}.stdout
echo ""
echo "stderr was:"
cat make-solvers-${PID}.stderr
if ${CI}; then
echo "stdout was:"
cat make-solvers-${PID}.stdout
echo ""
echo "stderr was:"
cat make-solvers-${PID}.stderr
else
echo "Last 10 lines of the stdout was:"
tail -n10 make-solvers-${PID}.stdout
echo ""
echo "Last 10 lines of the stderr was:"
tail -n10 make-solvers-${PID}.stderr
fi
echo ""
echo ""
echo ""
Expand Down

0 comments on commit e831009

Please sign in to comment.