File tree Expand file tree Collapse file tree 2 files changed +15
-7
lines changed
Expand file tree Collapse file tree 2 files changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -40,11 +40,11 @@ bump() {
4040 sed -i ' ' -E -e " s/v$YEAR [0-9]+/$VERSION /g" $f
4141 sed -i ' ' -E " s/v$(( YEAR - 1 )) [0-9]+/$VERSION /g" $f
4242 done
43- local src=bash.sh
44- for f in $CD /bash* ; do
45- if [[ " $( basename $f ) " != " $src " ]]; then
46- fi
47- done
43+ # local src=bash.sh
44+ # for f in $CD/bash*; do
45+ # if [[ "$(basename $f)" != "$src" ]]; then
46+ # fi
47+ # done
4848}
4949
5050bumpold () {
Original file line number Diff line number Diff line change @@ -40,6 +40,11 @@ bump() {
4040 sed -i ' ' -E -e " s/v$YEAR [0-9]+/$VERSION /g" $f
4141 sed -i ' ' -E " s/v$(( YEAR - 1 )) [0-9]+/$VERSION /g" $f
4242 done
43+ # local src=bash.sh
44+ # for f in $CD/bash*; do
45+ # if [[ "$(basename $f)" != "$src" ]]; then
46+ # fi
47+ # done
4348}
4449
4550bumpold () {
@@ -1238,9 +1243,12 @@ alias list-all-env-variables=list_all_env_variables list-all-variables=list_all_
12381243# is_darwin && realpathx() { [[ $1 == /* ]] && echo "$1" || { DIR="${1%/*}" && DIR=$(cd $DIR && pwd -P) && echo "$DIR/$(basename $1)"; }; } || realpathx() { readlink -f $*; }
12391244in_sourcing && {
12401245 SCRIPT=$( realpathx $( is_zsh_strict && echo " $0 " || echo " $BASH_SOURCE " ) ) && CD=$( dirname " $SCRIPT " ) && debug " $( safety " >> IN SOURCING (DEBUG=$DEBUG ), \$ 0=$0 , \$ _=$_ " ) "
1241- } || { SCRIPT=$( realpathx " $0 " ) && CD=$( dirname " $SCRIPT " ) && debug " $( safety " >> '$SCRIPT ' in '$CD ', \$ 0='$0 ','$1 '." ) " ; }
1246+ } || {
1247+ path_in_orb_host " $0 " && SCRIPT=" $0 " || SCRIPT=$( realpathx " $0 " )
1248+ CD=$( dirname " $SCRIPT " ) && debug " $( safety " >> '$SCRIPT ' in '$CD ', \$ 0='$0 ','$1 '." ) "
1249+ }
12421250if_vagrant && [ " $SCRIPT " == " /tmp/vagrant-shell" ] && { [ -d " $CD /ops.d" ] || CD=/vagrant/bin; }
1243- [ -L " $SCRIPT " ] && debug " $( safety " linked script found" ) " && SCRIPT=" $( realpathx " $SCRIPT " ) " && CD=" $( dirname " $SCRIPT " ) "
1251+ path_in_orb_host " $0 " && : || { [ -L " $SCRIPT " ] && debug " $( safety " linked script found" ) " && SCRIPT=" $( realpathx " $SCRIPT " ) " && CD=" $( dirname " $SCRIPT " ) " ; }
12441252# The better consice way to get baseDir, ie. $CD, is:
12451253# CD=$(cd `dirname "$0"`;pwd)
12461254# It will open a sub-shell to print the folder name of the running shell-script.
You can’t perform that action at this time.
0 commit comments