in reply to Re: Pass local bash script to remote host via SSH (updated)in thread Pass local bash script to remote host via SSH
Note you also need to check close for errors, and I would strongly recommend the list form of open. See Calling External Commands More Safely (near the bottom there's example code).
call it version 1.0
destroy all evidence that I tried
pay someone else to do it for me
have some cake
try two more times so my failure is statistically significant
Results (132 votes). Check out past polls.