I converted my python project to a .command file on mac. I was using relative paths to import various CSV files as follow:
import pandas as
df = pd.read_csv('my_file.csv')
It works perfectly since the code and the csv are in the same directory.
Now I converted the python project into a .command executable file by using the following method:
Added first line of Python script as #!/usr/bin/env python
Changed the extension of the file to .command
In Terminal used command chmod +x Test.command
The relative paths don't work anymore and I have to enter the entire path. How can make the paths relative again?