If any shell command fails, the whole script should fail. To avoid
future omissions, add this even for single-command scripts that use su
with heredoc syntax, as they might be extended or copied-and-pasted.
Extracted from a larger patch that wanted to use #error during
compilation, leading to the diagnosis of this problem.
Reviewed-by: Tristan Partin <tristan@partin.io> (earlier version)
Discussion: https://postgr.es/m/DDZP25P4VZ48.3LWMZBGA1K9RH%40partin.io
Backpatch-through: 15
# freebsd already takes longer than other platforms except for windows.
configure_script: |
su postgres <<-EOF
+ set -e
./configure \
--enable-cassert --enable-debug --enable-tap-tests \
--enable-nls \
configure_script: |
su postgres <<-EOF
+ set -e
./configure \
--enable-cassert --enable-debug --enable-tap-tests \
--enable-nls \
test_world_script: |
su postgres <<-EOF
+ set -e
ulimit -c unlimited # default is 0
make -s ${CHECK} ${CHECKFLAGS} -j${TEST_JOBS}
EOF