1 Commits

Author SHA1 Message Date
0882cfba59 testing _next_display 2020-04-26 23:49:05 -04:00

View File

@@ -1076,19 +1076,10 @@ EOF"
_setDisplayAndPort() { _setDisplayAndPort() {
# Check _display, else DISPLAY, else set to :0 by default # Check _display, else DISPLAY, else set to :0 by default
if [[ -n $_display ]]; then [[ -z $_display ]] && _display="${DISPLAY-":0"}"
_next_display="$_display"
elif [[ -n $DISPLAY ]]; then
_display="${DISPLAY}"
_displaynum="${_display#:}" # strip colon
_displaynum="${_displaynum%.*}" # strip suffix
_next_displaynum=$(( _displaynum + 1 ))
_next_display=":$_next_displaynum"
else
_display=":0"
_next_display=":1"
fi
_displaynum="${_display#:}" # strip colon
_displaynum="${_displaynum%.*}" # strip suffix
_port=$(( _displaynum + 5900 )) _port=$(( _displaynum + 5900 ))
} }
@@ -1191,6 +1182,19 @@ EOF"
_installPackage tigervnc-server _installPackage tigervnc-server
_getNextAvailableDisplay() {
:
}
_getNextAvailableDisplay
_next_displaynum=$(( _displaynum + 1 ))
_next_display=":$_next_displaynum"
#local _service_port=$(( _port + 1 ))
[[ -n $_debug ]] && echo "_next_display: $_next_display"
_setVNCPass _setVNCPass
if [[ -n $_novncauth ]]; then if [[ -n $_novncauth ]]; then