Automatically change directory when switching to su

Hello,

Is it possible to automatically change working directory when su via Putty?
I tried to do that when logging in with a wheel account, by making changes in Putty, but that didn't work.

Thank you,
 
su -l will get you to /root (simulate a login)
su -m will preserve your environment, shell history etc

depends on what are you trying to accomplish
 
Back
Top