Skip to content

Commit

Permalink
Make the install script a little bit safer when being piped
Browse files Browse the repository at this point in the history
  • Loading branch information
Glen Mailer committed Nov 28, 2019
1 parent 716811d commit f1cd9e8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,9 @@

set -o errexit

# Use a function to ensure connection errors don't partially execute when being piped
install() {

echo "Starting installation."

# GitHub's URL for the latest release, will redirect.
Expand Down Expand Up @@ -56,3 +59,7 @@ command -v circleci

# Delete the working directory when the install was successful.
rm -r "$SCRATCH"

}

install

0 comments on commit f1cd9e8

Please sign in to comment.