Terminal specific commands (STTY) under fvwm

I was using dtwm all this time. Recently switched to fvwm2. I am trying to start fvwm before “dtsession” and “ttsession” by adding the following lines to “.dtprofile”


eval source $HOME/.login

exec $HOME/bin/fvwm2.4.19/bin/fvwm -f themes-rc -s

And here is the actual start log:

$cat .dt/startlog
— Tue Jul 19 16:20:29 IST 2005
— /usr/dt/bin/Xsession starting…
— Xsession started by dtlogin
— sourcing /home/ben1234/.dtprofile…
[color=red]/usr/dt/bin/Xsession[342]: source: not found[/color]

Everything comes up fine… But my “.login” is sourced. Thus my terminal specific stty commands (eg: stty erase “^H” kill “^U” intr “^C” eof “^D” susp “^Z” dsusp “^Y”) are not executed because of this.

I don’t want to put them in “.cshrc” it is sourced everytime I open an xterm. Is there any other file where I can add these commands such that it is executed only once?


Yes, tell xterm not to invoke a login shell:

 xterm +ls

– Thomas Adam

I guess that if you want to add things that are executed only at startup, you can put them in .dtprofile.

However, stty commands should be executed by any interactive shell. Hence I suggest to put in you .cshrc

if ( $?prompt == 1 ) then stty erase "^H" kill "^U" intr "^C" eof "^D" susp "^Z" dsusp "^Y" endif

I figured out a solution…

Add this resource into your .Xdefaults.

XTerm*ttyModes: erase ^H intr ^C kill ^U eof ^D susp ^Z dsusp ^Y