Updated terminal emulator function. Fixed End of Time Launcher.
This commit is contained in:
parent
06c3d87db0
commit
69631769f8
@ -3,7 +3,7 @@ pushd "${mudPath%/*}"
|
|||||||
git pull | \
|
git pull | \
|
||||||
dialog --progressbox "Checking for updates, please wait..." -1 -1
|
dialog --progressbox "Checking for updates, please wait..." -1 -1
|
||||||
if [[ -n "${COLORTERM}" ]]; then
|
if [[ -n "${COLORTERM}" ]]; then
|
||||||
terminal_emulator tt++ ${mudPath##*/}
|
terminal_emulator "${mudPath%/*}" "tt++" "${mudPath##*/}"
|
||||||
else
|
else
|
||||||
tt++ ${mudPath##*/}
|
tt++ "${mudPath%/*}" "${mudPath##*/}"
|
||||||
fi
|
fi
|
||||||
|
@ -111,13 +111,16 @@ check_dependencies() {
|
|||||||
|
|
||||||
# Function to open a terminal emulator
|
# Function to open a terminal emulator
|
||||||
terminal_emulator() {
|
terminal_emulator() {
|
||||||
|
# Arguments workingDirectory, rest of arguments
|
||||||
|
local workingDir="$1"
|
||||||
|
shift
|
||||||
terminals=(
|
terminals=(
|
||||||
"lxterminal"
|
"lxterminal"
|
||||||
"mate-terminal"
|
"mate-terminal"
|
||||||
"gnome-terminal"
|
"gnome-terminal"
|
||||||
)
|
)
|
||||||
for i in "${terminals[@]}" ; do
|
for i in "${terminals[@]}" ; do
|
||||||
if command $i --working-directory="${game%/*}" -e $* ; then
|
if command $i --working-directory="${workingDir}" -e "$@" ; then
|
||||||
return
|
return
|
||||||
fi
|
fi
|
||||||
done
|
done
|
||||||
|
Loading…
Reference in New Issue
Block a user