Skip to content

Commit

Permalink
Upstream.
Browse files Browse the repository at this point in the history
  • Loading branch information
mirage335 committed Mar 28, 2024
1 parent 17aa7a9 commit 9338dc2
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 129 deletions.
2 changes: 1 addition & 1 deletion _lib/ubiquitous_bash
14 changes: 12 additions & 2 deletions compile.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ _ub_cksum_special_derivativeScripts_contents() {
#export ub_setScriptChecksum_disable='true'
( [[ -e "$0".nck ]] || [[ "${BASH_SOURCE[0]}" != "${0}" ]] || [[ "$1" == '--profile' ]] || [[ "$1" == '--script' ]] || [[ "$1" == '--call' ]] || [[ "$1" == '--return' ]] || [[ "$1" == '--devenv' ]] || [[ "$1" == '--shell' ]] || [[ "$1" == '--bypass' ]] || [[ "$1" == '--parent' ]] || [[ "$1" == '--embed' ]] || [[ "$1" == '--compressed' ]] || [[ "$0" == "/bin/bash" ]] || [[ "$0" == "-bash" ]] || [[ "$0" == "/usr/bin/bash" ]] || [[ "$0" == "bash" ]] ) && export ub_setScriptChecksum_disable='true'
export ub_setScriptChecksum_header='2591634041'
export ub_setScriptChecksum_contents='194997282'
export ub_setScriptChecksum_contents='1821205394'

# CAUTION: Symlinks may cause problems. Disable this test for such cases if necessary.
# WARNING: Performance may be crucial here.
Expand Down Expand Up @@ -5872,6 +5872,7 @@ _init_deps() {

export enUb_dev=""
export enUb_dev_heavy=""
export enUb_dev_heavy_atom=""

export enUb_generic=""

Expand Down Expand Up @@ -5957,6 +5958,12 @@ _deps_dev_heavy() {
export enUb_dev_heavy="true"
}

_deps_dev_heavy_atom() {
_deps_notLean
export enUb_dev_heavy="true"
export enUb_dev_heavy_atom="true"
}

_deps_cloud_heavy() {
_deps_notLean
export enUb_cloud_heavy="true"
Expand Down Expand Up @@ -6947,6 +6954,7 @@ _compile_bash_deps() {
if [[ "$1" == "monolithic" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

#_deps_cloud_heavy
Expand Down Expand Up @@ -7045,6 +7053,7 @@ _compile_bash_deps() {
if [[ "$1" == "core" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

#_deps_cloud_heavy
Expand Down Expand Up @@ -7143,6 +7152,7 @@ _compile_bash_deps() {
if [[ "$1" == "" ]] || [[ "$1" == "ubiquitous_bash" ]] || [[ "$1" == "ubiquitous_bash.sh" ]] || [[ "$1" == "complete" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

_deps_cloud_heavy
Expand Down Expand Up @@ -7514,7 +7524,7 @@ _compile_bash_shortcuts() {
( ( [[ "$enUb_dev_heavy" == "true" ]] || [[ "$enUb_metaengine" == "true" ]] ) || [[ "$enUb_calculators" == "true" ]] ) && includeScriptList+=( "shortcuts/dev/app/calculators"/scriptedIllustrator_terminal.sh )

[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devemacs.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devatom.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && [[ "$enUb_dev_heavy_atom" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devatom.sh )

[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_abstractfs" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app/eclipse"/deveclipse_java.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_abstractfs" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app/eclipse"/deveclipse_env.sh )
Expand Down
138 changes: 12 additions & 126 deletions ubiquitous_bash.sh
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ _ub_cksum_special_derivativeScripts_contents() {
#export ub_setScriptChecksum_disable='true'
( [[ -e "$0".nck ]] || [[ "${BASH_SOURCE[0]}" != "${0}" ]] || [[ "$1" == '--profile' ]] || [[ "$1" == '--script' ]] || [[ "$1" == '--call' ]] || [[ "$1" == '--return' ]] || [[ "$1" == '--devenv' ]] || [[ "$1" == '--shell' ]] || [[ "$1" == '--bypass' ]] || [[ "$1" == '--parent' ]] || [[ "$1" == '--embed' ]] || [[ "$1" == '--compressed' ]] || [[ "$0" == "/bin/bash" ]] || [[ "$0" == "-bash" ]] || [[ "$0" == "/usr/bin/bash" ]] || [[ "$0" == "bash" ]] ) && export ub_setScriptChecksum_disable='true'
export ub_setScriptChecksum_header='2591634041'
export ub_setScriptChecksum_contents='1148926990'
export ub_setScriptChecksum_contents='2633005665'

# CAUTION: Symlinks may cause problems. Disable this test for such cases if necessary.
# WARNING: Performance may be crucial here.
Expand Down Expand Up @@ -24354,130 +24354,6 @@ _ubdb() {
_bashdb "$scriptAbsoluteLocation" "$@"
}

_test_devatom() {
_wantGetDep rsync

_wantGetDep atom

#local atomDetectedVersion=$(atom --version | head -n 1 | cut -f 2- -d \: | cut -f 2- -d \ | cut -f 2 -d \. )
#! [[ "$atomDetectedVersion" -ge "27" ]] && echo atom too old && return 1

return 0
}

_install_fakeHome_atom() {
_link_fakeHome "$atomFakeHomeSource"/.atom .atom

_link_fakeHome "$atomFakeHomeSource"/.config/Atom .config/Atom
}

_set_atomFakeHomeSource() {
export atomFakeHomeSource="$scriptLib"/app/atom/home

if ! [[ -e "$atomFakeHomeSource" ]]
then
true
#export atomFakeHomeSource="$scriptLib"/ubiquitous_bash/_lib/app/atom/home
fi

if [[ ! -e "$scriptLib"/app/atom/home ]]
then
_messageError 'missing: atomFakeHomeSource= '"$atomFakeHomeSource" > /dev/tty
_messageFAIL
_stop 1
fi
}

_atom_user_procedure() {
_set_atomFakeHomeSource

export actualFakeHome="$instancedFakeHome"
#export actualFakeHome="$globalFakeHome"
export fakeHomeEditLib="false"
export keepFakeHome="true"

_install_fakeHome_atom

_fakeHome atom --foreground "$@"
}

_atom_user_sequence() {
_start

"$scriptAbsoluteLocation" _atom_user_procedure "$@"

_stop $?
}

_atom_user() {
_atom_user_sequence "$@" > /dev/null 2>&1 &
}

_atom_edit_procedure() {
_set_atomFakeHomeSource

export actualFakeHome="$instancedFakeHome"
#export actualFakeHome="$globalFakeHome"
export fakeHomeEditLib="true"
export keepFakeHome="true"

_install_fakeHome_atom

_fakeHome atom --foreground "$@"
}

_atom_edit_sequence() {
_start

_atom_edit_procedure "$@"

_stop $?
}

_atom_edit() {
"$scriptAbsoluteLocation" _atom_edit_sequence "$@" > /dev/null 2>&1 &
}

_atom_config() {
_set_atomFakeHomeSource

export ATOM_HOME="$atomFakeHomeSource"/.atom
atom "$@"
}

_atom_tmp_procedure() {
_set_atomFakeHomeSource

mkdir -p "$safeTmp"/atom

rsync -q -ax --exclude "/.cache" "$atomFakeHomeSource"/.atom/ "$safeTmp"/atom/

export ATOM_HOME="$safeTmp"/atom
atom --foreground "$@"
unset ATOM_HOME
}

_atom_tmp_sequence() {
_start

_atom_tmp_procedure "$@"

_stop $?
}

_atom_tmp() {
"$scriptAbsoluteLocation" _atom_tmp_sequence "$@" > /dev/null 2>&1 &
wait
}

_atom() {
_atom_tmp "$@"
}

_ubide() {
_atom . ./ubiquitous_bash.sh "$@"
}

_set_java__eclipse() {
_set_java_openjdk "$@"
}
Expand Down Expand Up @@ -51566,6 +51442,7 @@ _init_deps() {

export enUb_dev=""
export enUb_dev_heavy=""
export enUb_dev_heavy_atom=""

export enUb_generic=""

Expand Down Expand Up @@ -51651,6 +51528,12 @@ _deps_dev_heavy() {
export enUb_dev_heavy="true"
}

_deps_dev_heavy_atom() {
_deps_notLean
export enUb_dev_heavy="true"
export enUb_dev_heavy_atom="true"
}

_deps_cloud_heavy() {
_deps_notLean
export enUb_cloud_heavy="true"
Expand Down Expand Up @@ -52641,6 +52524,7 @@ _compile_bash_deps() {
if [[ "$1" == "monolithic" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

#_deps_cloud_heavy
Expand Down Expand Up @@ -52739,6 +52623,7 @@ _compile_bash_deps() {
if [[ "$1" == "core" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

#_deps_cloud_heavy
Expand Down Expand Up @@ -52837,6 +52722,7 @@ _compile_bash_deps() {
if [[ "$1" == "" ]] || [[ "$1" == "ubiquitous_bash" ]] || [[ "$1" == "ubiquitous_bash.sh" ]] || [[ "$1" == "complete" ]]
then
_deps_dev_heavy
#_deps_dev_heavy_atom
_deps_dev

_deps_cloud_heavy
Expand Down Expand Up @@ -53208,7 +53094,7 @@ _compile_bash_shortcuts() {
( ( [[ "$enUb_dev_heavy" == "true" ]] || [[ "$enUb_metaengine" == "true" ]] ) || [[ "$enUb_calculators" == "true" ]] ) && includeScriptList+=( "shortcuts/dev/app/calculators"/scriptedIllustrator_terminal.sh )

[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devemacs.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devatom.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && [[ "$enUb_dev_heavy_atom" == "true" ]] && includeScriptList+=( "shortcuts/dev/app"/devatom.sh )

[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_abstractfs" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app/eclipse"/deveclipse_java.sh )
[[ "$enUb_fakehome" == "true" ]] && [[ "$enUb_abstractfs" == "true" ]] && [[ "$enUb_dev_heavy" == "true" ]] && includeScriptList+=( "shortcuts/dev/app/eclipse"/deveclipse_env.sh )
Expand Down

0 comments on commit 9338dc2

Please sign in to comment.