I'm using tsch through PuTTY, and let's start by this: please don't try to convince me to migrate to another shell...:)It's being a long time that commands like scp and less didn't work well for me. After searching I found out, as many others, that this was because of echo commands that interrupt scp and less.I found out that moving those 'echoing commands' to the .login file instead of .cshrc or .self_schrc solved the problem.However, there's one issue: I want to change title of the PuTTY window according to the directory I'm currently in. I managed to do so by aliasing setprompt printf \033]0 and execute setpropmt. But then again - this printf ruins my scp and less. And this time - I can't move the execution of setprompt into .login, for certain reason.Now, I read here and there that you can leave those 'echo commands' in the .cshrc files if you're checking for interactive shell, since less and scp won't execute lines of interactive shell.I tried few methods, such as:if { tty -s } thenorif ($?prompt) thenbut it seems that less is still 'reading' those line, and hence - giving me wrong output.What am I doing wrong here?
Prevent scp and less commands reading interactive tcsh script
shell;scp;less;tcsh;interactive