change default username when ssh to another pc
- by Tom
When I ssh between different pcs I can omit my username (tom) and just type
ssh pc_name
instead of
ssh tom@pc_name
I like this feature, and have got into the habit of using it.
Unfortunately, on one of my computers I went for the user name tommy. Everytime I connect to this computer I forget to write tommy@creative_pc and wonder why my password doesn't work. Is there a way to tell ssh what user name to use when the username is omitted?
Edit: Just found the following question that is similar: How to make ssh log in as the right user? It didn't come up on my initial search.