title: How do I execute a remote Python file from a .sh executable?
body: <p>I am using a Mac.</p>
  
  <p>I have a Python file on a server. Let's say it's here: <a href="http://jake.com/python_file.py" rel="nofollow noreferrer">http://jake.com/python_file.py</a>. I want to make a script that I can <a href="https://stackoverflow.com/questions/8409946/how-do-i-make-this-file-sh-executable-via-double-click">run in Terminal by double-clicking</a> and will run the Python file in Terminal on the local machine. Any ideas?</p>
  
  <p>Would I have to use SSH to connect to the server and <a href="https://stackoverflow.com/questions/9427553/how-to-download-a-file-from-server-using-ssh">download the file</a> to a temporary location on the hard drive (/tmp?) and then delete it when I'm done? But there's another problem with this. It would have to download the Python file to a location in the user's home folder because I don't think users have the necessary permissions to write to the folder /tmp or /var or something like that.</p>
  
  <p>I was looking around for a solution to my problem and found <a href="http://www.cyberciti.biz/faq/how-to-execute-a-remote-script-unix/" rel="nofollow noreferrer">this</a>. It talks about how to execute a remote script using SSH on unix but I tried doing this with my Python file and it didn't work.</p>
  
  <p>In case you didn't realize, the main reason why I am looking to do this is so that a user can run the file locally but they are unable to read/edit the actual Python file which is stored on the server.</p>
  
  <p>If anyone has any ideas on how to accomplish this (whether using the ideas mentioned above or not) please let me know I'd really appreciate it!</p>
  
  <p>Thanks,
  Jake</p>