Enable "set -euo pipefail" in all bash scripts.
This enables "set -e", "set -u", and "set -o pipefail", which catch common errors.
This commit is contained in:
@@ -1,5 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
set -euo pipefail
|
||||||
|
|
||||||
# Usage: check-rustfmt.sh [--install]
|
# Usage: check-rustfmt.sh [--install]
|
||||||
#
|
#
|
||||||
# Check that the desired version of rustfmt is installed.
|
# Check that the desired version of rustfmt is installed.
|
||||||
|
|||||||
@@ -1,10 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
# Format all sources using rustfmt.
|
# Format all sources using rustfmt.
|
||||||
|
|
||||||
# Exit immediately on errors.
|
|
||||||
set -e
|
|
||||||
|
|
||||||
cd $(dirname "$0")
|
cd $(dirname "$0")
|
||||||
|
|
||||||
# Make sure we can find rustfmt.
|
# Make sure we can find rustfmt.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
set -euo pipefail
|
||||||
cd $(dirname "$0")
|
cd $(dirname "$0")
|
||||||
topdir=$(pwd)
|
topdir=$(pwd)
|
||||||
|
|
||||||
|
|||||||
@@ -1,4 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
|
set -euo pipefail
|
||||||
|
|
||||||
# This is the top-level test script:
|
# This is the top-level test script:
|
||||||
#
|
#
|
||||||
@@ -10,9 +11,6 @@
|
|||||||
#
|
#
|
||||||
# All tests run by this script should be passing at all times.
|
# All tests run by this script should be passing at all times.
|
||||||
|
|
||||||
# Exit immediately on errors.
|
|
||||||
set -e
|
|
||||||
|
|
||||||
# Repository top-level directory.
|
# Repository top-level directory.
|
||||||
cd $(dirname "$0")
|
cd $(dirname "$0")
|
||||||
topdir=$(pwd)
|
topdir=$(pwd)
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
set -e
|
set -euo pipefail
|
||||||
cd $(dirname "$0")
|
cd $(dirname "$0")
|
||||||
|
|
||||||
runif() {
|
runif() {
|
||||||
|
|||||||
Reference in New Issue
Block a user