From 38dfba78b82e97c5424809d58fa5500bcb52b04f Mon Sep 17 00:00:00 2001 From: Dan Buch Date: Mon, 21 Jul 2014 10:34:34 -0400 Subject: [PATCH] Making all prefer-binary bits consistent --- README.md | 2 +- scripts/install | 5 +++-- tests/scenario/gvm_install_1.2_preferbinary_comment_test.sh | 2 +- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 58722ed..892ed49 100644 --- a/README.md +++ b/README.md @@ -42,7 +42,7 @@ Additional options can be specified when installing Go: -pb, --with-protobuf Install Go protocol buffers. -b, --with-build-tools Install package build tools. -B, --binary Only install from binary. - --preferbinary Attempt a binary install, falling back to source. + --prefer-binary Attempt a binary install, falling back to source. -h, --help Display this message. List Go Versions diff --git a/scripts/install b/scripts/install index 4ac98f5..0ba7809 100755 --- a/scripts/install +++ b/scripts/install @@ -8,6 +8,7 @@ function show_usage() { echo " -pb, --with-protobuf Install Go protocol buffers." echo " -b, --with-build-tools Install package build tools." echo " -B, --binary Only install from binary." + echo " --prefer-binary Attempt a binary install, falling back to source." echo " -h, --help Display this message." } @@ -39,7 +40,7 @@ read_command_line() { INSTALL_SOURCE="binary" ;; --prefer-binary) - INSTALL_SOURCE="preferbinary" + INSTALL_SOURCE="prefer-binary" ;; -h|--help) show_usage @@ -309,7 +310,7 @@ main() { if [[ "x$INSTALL_SOURCE" == "xbinary" ]]; then install_go_binary - elif [[ "x$INSTALL_SOURCE" == "xpreferbinary" ]]; then + elif [[ "x$INSTALL_SOURCE" == "xprefer-binary" ]]; then install_go_binary || { display_message "Falling back to source installation of $GO_NAME" install_from_source diff --git a/tests/scenario/gvm_install_1.2_preferbinary_comment_test.sh b/tests/scenario/gvm_install_1.2_preferbinary_comment_test.sh index ce6cbc2..9ee649b 100644 --- a/tests/scenario/gvm_install_1.2_preferbinary_comment_test.sh +++ b/tests/scenario/gvm_install_1.2_preferbinary_comment_test.sh @@ -1 +1 @@ -gvm install go1.2 --preferbinary #status=0 +gvm install go1.2 --prefer-binary #status=0