add "set -o pipefail".
Merge pull request #15 from hansode/pipefail

add "set -o pipefail".