I have a python script that takes in a .txt file and outputs a .txt file. I want to create a bash file that I can click on from my desktop to execute the python script.
So far I have:
#!/bin/bash
cd /Desktop;
cd ./py-data;
python ./grab.py;
exit;
This just opens up the python script. Ideally I would like to click on the bash script and have the python script to run in the back ground and just produce the output without having to open the python script.
Solution:
change py.bat to py.command
at terminal:
$ cd ~/Desktop $ chmod 755 py.command
open code on vim and place in (from: ./configure : /bin/sh^M : bad interpreter):
:set fileformat=unix
Changed code too:
#!bin/bash cd ~/Desktop python search.py exit;