| Use ssh -t Hello,
I had the same request, and a friend of mine who just has a degree in Linux Mastership gave me the answer:
Simply do something like:
ssh -t YOURHOST "bash --rcfile PATH_TO_RCFILE"
bash will be executed on the remote host, and bash will execute the specfied RCFILE at startup, and connection will remain open. -t is to have the current terminal forwarded to the ssh session so that you have a real terminal.
You can have some variant on the same kind, still use ssh -t. Like if screen is installed, you can do:
ssh -t YOURHOST screen
Hope it helps!
ps: another master in linux told me this other solution: "ssh YOURHOST bash --rcfile YOUR_RC_FILE -i". But then you don't have a real terminal, and some stuff will not work correctly (like tab auto-completion).
Last edited by fuujuhi; 09-09-2008 at 01:17 PM..
Reason: Forgot quote around ssh command...
|