OraMatt: YABAOracle

Yet Another Blog About Oracle

, ,

Applescript for SSH-ing

Hi All,

I thought I’d share a little Applescript app I wrote up to help me in my day to day SSHing…

I like to have my various connections to different severs color coded to help me know which system I’m about to break.

To that end I wrote up this little script.

Just copy & paste into Applescript Editor and Save As an Application or whatever

Enjoy

------------------------------------------------------------------------------
-- Author: Matt D
-- Created: July 16, 2012
-- Contact: oramatt.wordpress.com
 
--Display Dialog and Get Input for Server
display dialog "SSH to What Sever?" default answer "user@server"
set theServer to (text returned of result)
 
-- Display Dialog and Get Input for BackGround Color
display dialog "What color would you like the background?" default answer "green"
set theBGColor to (text returned of result)
 
-- Display Dialog and Get Input for Text Color
display dialog "What color would you like the text?" default answer "black"
set theTXTColor to (text returned of result)
 
do shell script "open -a Terminal"
 
tell application "Terminal"
 

do script "ssh " & theServer
 

set the background color of window 1 to theBGColor
set the normal text color of window 1 to theTXTColor
set the number of columns of window 1 to 150
set the number of rows of window 1 to 50
set the position of window 1 to {350, 150}
 

 

 

end tell

------------------------------------------------------------------------------
 

Leave a comment

Navigation

About

I’m Matt and I do Oracle things.