views:

284

answers:

3

I am trying to create a link to open an ssh connection to another computer. I am an OS X 10.5.7 and Ubuntu 9.04 user. I am tempted to create a symbolic link as such:

ln -s "ssh user@computer_name" computer_name

I know this is wrong. Could someone point me in the right direction?

+1  A: 

Stick the command in a bash file somewhere and symbolic link to that.

Stefan Kendall
+1  A: 

Edit ~/.profile and add the following:

computer_name(){
    ssh user@computer_name
}

Log out of the Terminal and reopen the Terminal. The command "computer_name" should now work.

Michael Aaron Safyan
+3  A: 

you can create an alias somewhere in the file your shell runs when it starts (i.e. .bashrc for bash):

alias computer_name="ssh user@computer_name"
newacct