When I'm working on my FreeBSD server's ssh, it always assume that terminal width is 80 columns. E.g. man pages show up in one thin column and all programs that use COLUMNS and LINES environment variables to guess terminal size work only in 80 default columns.

Are there any way to make tcsh correctly set this environment vars and send them to child programs?

link|improve this question
Now posted as a comment: what terminal are you using that resizing doesn't work? – Chris S Oct 6 '10 at 15:40
I currently use MacOS X+Terminal, verified on Ubuntu 10.04+lxterminal and Windows 7+Putty, the very same result everywhere. – Yorik.sar Oct 6 '10 at 23:50
feedback

2 Answers

Not sure about tcsh, but for bash, sh and ksh:

eval `resize`

Should do the trick.

link|improve this answer
eval `resize -c` – Dennis Williamson Oct 6 '10 at 13:13
resize: Command not found. – Yorik.sar Oct 6 '10 at 14:24
This usually comes bundled with the X server - but the program itself is fairly simple. A quick google turned up this: ohse.de/uwe/software/resize.c.html – symcbean Oct 7 '10 at 11:53
feedback

The resize script comes with xterm which you can install from ports (although you will get libX11 etc with it).

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.