diff --git a/cover b/cover index 5f65df2bf..b7ad39113 100755 --- a/cover +++ b/cover @@ -1,8 +1,9 @@ -#!/bin/bash -e +#!/usr/bin/env bash # # Generate coverage HTML for a package # e.g. PKG=./unit ./cover # +set -e if [ -z "$PKG" ]; then echo "cover only works with a single package, sorry" diff --git a/scripts/build-aci b/scripts/build-aci index 12da78288..9d5464ffa 100755 --- a/scripts/build-aci +++ b/scripts/build-aci @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash # A non-installed actool can be used, for example: # ACTOOL=../../appc/spec/bin/actool diff --git a/scripts/build-docker b/scripts/build-docker index 986032ec1..b29afb940 100755 --- a/scripts/build-docker +++ b/scripts/build-docker @@ -1,4 +1,4 @@ -#!/usr/bin/bash +#!/usr/bin/env bash tar cv --files-from /dev/null | docker import - scratch cat < Dockerfile diff --git a/scripts/genproto.sh b/scripts/genproto.sh index 7f1f0ac59..1245bc922 100755 --- a/scripts/genproto.sh +++ b/scripts/genproto.sh @@ -1,8 +1,9 @@ -#!/bin/bash -e +#!/usr/bin/env bash # # Generate all etcd protobuf bindings. # Run from repository root. # +set -e PREFIX="github.com/coreos/etcd/Godeps/_workspace/src" DIRS="./wal/walpb ./etcdserver/etcdserverpb ./snap/snappb ./raft/raftpb ./storage/storagepb" @@ -27,7 +28,7 @@ popd export PATH="${GOBIN}:${PATH}" # copy all proto dependencies inside etcd to gopath -for dir in ${DIRS}; do +for dir in ${DIRS}; do mkdir -p ${GOPATH}/src/github.com/coreos/etcd/${dir} pushd ${dir} cp *.proto ${GOPATH}/src/github.com/coreos/etcd/${dir} diff --git a/test b/test index 88c23a9b7..bb6a52e80 100755 --- a/test +++ b/test @@ -1,4 +1,4 @@ -#!/bin/bash -e +#!/usr/bin/env bash # # Run all etcd tests # ./test @@ -8,6 +8,7 @@ # # PKG=./wal ./test # PKG=snap ./test +set -e # Invoke ./cover for HTML output COVER=${COVER:-"-cover"}