|
|
(Rewrite) Another way to create quick-access SSH shortcuts
Fantastic hint. I've taken the time to rewrite portions of your script, adding some extra features.
My new version allows for specifying username and port in the .hosts file. In adding this support, I've changed a few things with regard to $term_file, so that different user names to the same host don't clobber each other; ditto for ports.
Enjoy!
JP
P.S. This has already been formatted and should be A-O.K. to just select, copy, and paste. The original poster named the file "mkterms.phps" and have kept that name. You might like it too. :-)
JP
---
(Rewrite) Another way to create quick-access SSH shortcuts
There's still a bug, if anyone wants to get to it before me: (1) white space is NOT ignored, which can be confusing. The original script did not have this problem for white space at the end of the line, but did for white space at the beginning. My version keeps all white space, except for whitespace *after* the port number (end of the line).
(Rewrite) Another way to create quick-access SSH shortcuts
That might be useful for a larger audience, so thanks for the additions. In my particular case, I had my reasons for the way it was.
|
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysNo new commentsLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.08 seconds |
|