diff --git a/Cargo.toml b/Cargo.toml
index 31e5675dc0e6288bfaf3598341c10c803f1369c8..2b649604d0bc58810d3cb6447d6cbdc13d97d6fb 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -42,6 +42,7 @@ rand = "0.3"
 git = "https://github.com/redox-os/app-dirs-rs.git"
 
 [profile.release]
+debug = true
 lto = true
 panic = "abort"
 
diff --git a/examples/run_examples.sh b/examples/run_examples.sh
index bfea101f10ff8036fe337017f67ecc8082e4312c..a10e9f17e5611c84537c05ebd4945042804a07eb 100755
--- a/examples/run_examples.sh
+++ b/examples/run_examples.sh
@@ -1,5 +1,7 @@
 #!/usr/bin/env bash
 
+set -e -u -o pipefail
+
 RED='\033[0;31m'
 GREEN='\033[0;32m'
 NC='\033[0m' # No Color
@@ -49,6 +51,7 @@ function check_return_value {
 # Build debug binary
 cargo build
 
+set +e
 # Iterate over every Ion script in examples directory
 for i in $EXAMPLES_DIR/*.ion; do
     check_return_value $i;