chore(install): fix install scripts & improve local usage (#2041)

Fix a few minor problems with Travis install & build scripts.
Other changes allow `before-install.sh` to be run locally.
This commit is contained in:
Patrice Chalin 2016-08-11 17:44:42 -07:00 committed by Kathy Walrath
parent 7075cdbefa
commit b772079bc9
3 changed files with 8 additions and 8 deletions

View File

@ -2,13 +2,11 @@
set -e -o pipefail set -e -o pipefail
./scripts/env-info-and-check.sh [[ -z "$NGIO_ENV_DEFS" ]] && . ./scripts/env-set.sh
[[ -n "$TRAVIS" ]] && . ./scripts/env-info-and-check.sh
if [[ 0 ]]; then if [ -z "$TRAVIS" ]; then
# Doesn't seem to be necessary. Disabling.
travis_fold start install.globals
set -x set -x
npm install -g gulp --no-optional npm install -g gulp --no-optional
set +x set +x
travis_fold end install.globals
fi fi

View File

@ -2,6 +2,8 @@
set -e -o pipefail set -e -o pipefail
[[ -z "$NGIO_ENV_DEFS" ]] && . ./scripts/env-set.sh
travis_fold start env_info travis_fold start env_info
echo ENVIRONMENT INFO echo ENVIRONMENT INFO
travis_fold start env_info.path travis_fold start env_info.path
@ -11,7 +13,7 @@ echo
travis_fold end env_info.path travis_fold end env_info.path
travis_fold start env_info.home travis_fold start env_info.home
echo Home: $HOME echo Home: $HOME
ls ~ -la ls -la ~
echo echo
travis_fold end env_info.home travis_fold end env_info.home
travis_fold start env_info.pwd travis_fold start env_info.pwd

View File

@ -3,7 +3,7 @@
if [[ -z "$NGIO_ENV_DEFS" ]]; then if [[ -z "$NGIO_ENV_DEFS" ]]; then
export ANSI_YELLOW="\033[33;1m" export ANSI_YELLOW="\033[33;1m"
export ANSI_RESET="\033[0m" export ANSI_RESET="\033[0m"
echo -e "${ANSI_YELLOW}Setting environment variables from scripts/env.sh${ANSI_RESET}" echo -e "${ANSI_YELLOW}Setting environment variables from scripts/env-set.sh${ANSI_RESET} "
export NGIO_ENV_DEFS=1 export NGIO_ENV_DEFS=1
@ -12,7 +12,7 @@ if [[ -z "$NGIO_ENV_DEFS" ]]; then
if [ ! $(type -t travis_fold) ]; then if [ ! $(type -t travis_fold) ]; then
# In case this is being run locally. Turn travis_fold into a noop. # In case this is being run locally. Turn travis_fold into a noop.
travis_fold () { return; } travis_fold () { true; }
# Alternative definition: # Alternative definition:
# travis_fold () { echo -en "travis_fold:${1}:${2}"; } # travis_fold () { echo -en "travis_fold:${1}:${2}"; }
fi fi