Putty - window size

Hi Guys,

When I use putty and maximize it, then the second half of the emulator window is not utilized and used! I mean the mouse cursor is at the half of the page not at the bottom! i have to once minimize and maximize the window to tell putty that i am going to use the maxmized window...is there any way to resolve this?

What is the value of the TERM environmental variable? Or term, if using a csh variant.

To "fix" this, I run:

eval `resize`

its vt220

i know even resize itself works fine. but I need to put this resize command into my screen script. I am using 'screen' in putty to make me be able to have multiple screens in order to connect to multiple servers. have you worked with screen? below is the piece of script that I use to connect to the servers but i have tried to put the resize command anywhere in the code to be run right after I am logged in to server but the resize command seems to be skipped!

# runs SSH to a host in new screen window and sets title to session parameters
#screen -t $1 ssh $1

if [ "$2X" = "X" ]
  then
      screen -t $1@testuser1 swrap -t user1@$1
  else
      if [ "$2" = "root" ]
        then
          screen -t $1@$2 swrap -t $2@$1
        else
          screen -t $1@$2 swrap -t useradmin@$1 "
          . /etc/profile
          export WSID=W1
          sudo su - $2"
          resize

      fi

fi

I know many people who use man screen (linux), I am just not one of them -- except when I know I need to disconnect and reconnect to a session. I mostly open up multiple PuTTY sessions. I do not know how to propogate a resizing event through the layers, it is a problem I encounter with ssh-ing to other systems. I do like your script, although the double quote on the end of the sudo su ... line probably be moved to the end of the resize line.

yeah sorry the quote should go to after the resize command.