CS-FreeStyle / 10000-How-To-Do-in-CS

1 stars 0 forks source link

xterm with full screen #110

Open liuty10 opened 3 years ago

liuty10 commented 3 years ago

/usr/bin/xterm -maximized -ls -title "xterm" & twm

liuty10 commented 3 years ago

https://unix.stackexchange.com/questions/177364/vnc-unable-to-get-a-shell-prompt-with-the-default-opened-terminal-application https://www.linuxquestions.org/questions/linux-newbie-8/how-to-launch-xterm-maximized-683966/

liuty10 commented 3 years ago

if [ "$TVNC_WM" != "" ]; then

/usr/bin/xterm -geometry 80x24+10+10 -ls -title "xterm" & twm

/usr/bin/xterm -maximized -ls -title "xterm" & twm if [ -x "$TVNC_WM" ]; then exec $TVNC_SSHAGENT $TVNC_VGLRUN "$TVNC_WM" else exec $TVNC_SSHAGENT $TVNC_VGLRUN sh "$TVNC_WM" fi else echo "No window manager startup script found. Use the TVNC_WM environment" echo "variable to specify the path to a window manager startup script or" echo "executable. Falling back to TWM." which twm >/dev/null && { if [ -f $HOME/.Xresources ]; then xrdb $HOME/.Xresources; fi xsetroot -solid grey xterm -geometry 80x24+10+10 -ls -title "$VNCDESKTOP Desktop" & twm } || { echo "TWM not found. I give up." exit 1 } fi

liuty10 commented 3 years ago

How to start VNC with specific resolution /opt/TurboVNC/bin/vncserver -securitytypes None -geometry 1280x720

how to connect from client /opt/TurboVNC/bin/vncviewer -DesktopSize Server 10.100.233.197:5901

liuty10 commented 3 years ago

Or you can change resolution at client side: /opt/TurboVNC/bin/vncviewer -DesktopSize 1280x720+0+0 10.100.233.197:5901

liuty10 commented 3 years ago

If there is no window manager, use the following scripts:

/usr/bin/xterm -maximized -ls -title "xterm" & x-window-manager & if [ -x "$TVNC_WM" ]; then exec $TVNC_SSHAGENT $TVNC_VGLRUN "$TVNC_WM" else exec $TVNC_SSHAGENT $TVNC_VGLRUN sh "$TVNC_WM" fi

Attention: if you start turbovnc remotely using scripts contains ssh command. Similarly, you should also kill turbovnc remotely using scripts contain ssh and kill :number.