Hi,
I’m still very new to applescript and maybe i’m doing things beyond my capabilities, but here what i got… I need to scp a file to certain ip address… i can do it with the script below:
tell application "Terminal"
activate
do script "cd ~ ; cd .ssh ; scp authorized_keys2 music@172.16.197.149:~/.ssh/" in front window
end tell
BUT I would like it to promt me for the ip address… something like this :
set remoteHostByIP to text returned of («event panSdlog» "Please enter IP of Client:" given «class btns»:{"Cancel", "Connect"}, «class dflt»:"Connect", «class dtxt»:"") as Unicode text
tell application "Terminal"
activate
do script "cd ~ ; cd .ssh ; scp authorized_keys2 music@" & remoteHostByIP & ":~/.ssh/" in front window
end tell
Obviously that doesn’t work… what is the syntax that i need to use? Also is there an easy way to have it input the password which is always the same?
Thanks for any help i get on this… very very apreciated