submitting rsync password with do shell script in one line

a little help, please

how can i get this working in one line so that i am not prompted for the password and still get the_image in there.


set the_image to "test_image.gif"
tell application "Finder"
	do shell script "rsync -avz -e ssh user@host.com:myurl.com/" & the_image & " Desktop/dl_folder/" & the_image	
	delay 5
	do shell script "password"
end tell

note: i tried defining a password-file, but am not sure if I wrote the body of the file correctly, nor if the defined path is correct, so i’m not relying on that.

I figured out how to deal with the password prompt.

now, how can i embed the ‘the_image_name’ variable?


--hardcoded for testing purposes
set the_image_name to "logo.gif"

tell application "Finder" to do script "rsync ... [url=http://www.url.com/folder/]http://www.url.com/folder/"[/url] & the_image_name