fix things (spaces, cont lines) causing editor to weirdly re/indent
This commit is contained in:
parent
cc1a63c096
commit
df82c1cc44
22
.bash_env
22
.bash_env
|
@ -38,8 +38,7 @@ nac () {
|
||||||
alias denac='deactivate_node'
|
alias denac='deactivate_node'
|
||||||
alias deactivate_node='__denac'
|
alias deactivate_node='__denac'
|
||||||
case $- in
|
case $- in
|
||||||
*i*) __npm_completion \
|
*i*) __npm_completion; echo "Now using NODEENV node $NODE_VERSION (npm v$(npm --version))" ;;
|
||||||
; echo "Now using NODEENV node $NODE_VERSION (npm v$(npm --version))";;
|
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
export -f nac
|
export -f nac
|
||||||
|
@ -56,7 +55,7 @@ complete -F __nac nac
|
||||||
__denac () {
|
__denac () {
|
||||||
____denac
|
____denac
|
||||||
case $- in
|
case $- in
|
||||||
*i*) echo "Now using system node $(node --version) (npm v$(npm --version))";;
|
*i*) echo "Now using system node $(node --version) (npm v$(npm --version))" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
export -f __denac
|
export -f __denac
|
||||||
|
@ -83,8 +82,8 @@ nvm_load () {
|
||||||
alias nvm='__nvm_mask'
|
alias nvm='__nvm_mask'
|
||||||
__nvm_mask () {
|
__nvm_mask () {
|
||||||
case "$*" in
|
case "$*" in
|
||||||
unload*) __nvm_unload;;
|
unload*) __nvm_unload ;;
|
||||||
*) unalias nvm; nvm "$@"; alias nvm='__nvm_mask';;
|
*) unalias nvm; nvm "$@"; alias nvm='__nvm_mask' ;;
|
||||||
esac
|
esac
|
||||||
export NODE_VERSION=$(node --version)
|
export NODE_VERSION=$(node --version)
|
||||||
}
|
}
|
||||||
|
@ -100,19 +99,18 @@ __nvm_load () {
|
||||||
. ${HOME}/.nvm/nvm.sh &> /dev/null
|
. ${HOME}/.nvm/nvm.sh &> /dev/null
|
||||||
if [[ (-z $(nvm alias default)) && ($1 != "no-auto-lts") ]]; then
|
if [[ (-z $(nvm alias default)) && ($1 != "no-auto-lts") ]]; then
|
||||||
case $- in
|
case $- in
|
||||||
*i*) nvm install --lts;;
|
*i*) nvm install --lts ;;
|
||||||
*) nvm install --lts &> /dev/null;;
|
*) nvm install --lts &> /dev/null ;;
|
||||||
esac
|
esac
|
||||||
local auto_lts=
|
local auto_lts=
|
||||||
fi
|
fi
|
||||||
case $- in
|
case $- in
|
||||||
*i*) __npm_completion;;
|
*i*) __npm_completion ;;
|
||||||
esac
|
esac
|
||||||
if [[ (! -v auto_lts) \
|
if [[ (! -v auto_lts) && ($(which node) = "${HOME}/.nvm/versions/"*) ]]; then
|
||||||
&& ($(which node) = "${HOME}/.nvm/versions/"*) ]]; then
|
|
||||||
export NODE_VERSION=$(node --version)
|
export NODE_VERSION=$(node --version)
|
||||||
case $- in
|
case $- in
|
||||||
*i*) echo "Now using NVM node $NODE_VERSION (npm v$(npm --version))";;
|
*i*) echo "Now using NVM node $NODE_VERSION (npm v$(npm --version))" ;;
|
||||||
esac
|
esac
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
@ -121,7 +119,7 @@ export -f __nvm_load
|
||||||
__nvm_unload () {
|
__nvm_unload () {
|
||||||
____nvm_unload
|
____nvm_unload
|
||||||
case $- in
|
case $- in
|
||||||
*i*) echo "Now using system node $NODE_VERSION (npm v$(npm --version))";;
|
*i*) echo "Now using system node $NODE_VERSION (npm v$(npm --version))" ;;
|
||||||
esac
|
esac
|
||||||
}
|
}
|
||||||
export -f __nvm_unload
|
export -f __nvm_unload
|
||||||
|
|
6
run.sh
6
run.sh
|
@ -3,8 +3,8 @@
|
||||||
run_embark () {
|
run_embark () {
|
||||||
local oldopts=""
|
local oldopts=""
|
||||||
case $- in
|
case $- in
|
||||||
*e*) oldopts="set -e";;
|
*e*) oldopts="set -e" ;;
|
||||||
*) oldopts="set +e";;
|
*) oldopts="set +e" ;;
|
||||||
esac
|
esac
|
||||||
if [[ $(shopt -po history) = "set -o history" ]]; then
|
if [[ $(shopt -po history) = "set -o history" ]]; then
|
||||||
oldopts="$oldopts; set -o history"
|
oldopts="$oldopts; set -o history"
|
||||||
|
@ -72,7 +72,7 @@ run_embark () {
|
||||||
local -a cmd=( "$@" )
|
local -a cmd=( "$@" )
|
||||||
case $1 in
|
case $1 in
|
||||||
-V|--version|-h|--help|new|demo|build|run|blockchain|simulator|test|\
|
-V|--version|-h|--help|new|demo|build|run|blockchain|simulator|test|\
|
||||||
reset|graph|upload|version) cmd=( "embark" "$cmd" );;
|
reset|graph|upload|version) cmd=( "embark" "$cmd" ) ;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
docker run \
|
docker run \
|
||||||
|
|
Loading…
Reference in New Issue