Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

usr/bin/env: bad interpreter Permission Denied --> how to change the fstab

I'm using cygwin on windows 7 to run a bash script that activates a python script, and I am getting the following error:

myscript.script: /cydrive/c/users/mydrive/folder/myscript.py: usr/bin/env: bad interpreter: Permission Denied.

I'm a total newbie to programming, so I've looked around a bit, and I think this means Python is mounted on a different directory that I don't have access to. However, based on what I found, I have tried to following things:

  • Change something (from user to exec) in the fstab: however, my fstab file is all commented out and only mentions what the defaults are. I don't know how I can change the defaults. The fstab.d folder is empty.
  • change the #! usr/bin/env python line in the script to the actual location of Python: did not work, same error
  • add a PYTHONPATH to the environment variables of windows: same error.

I would really appreciate it if someone could help me out with a suggestion!

like image 891
Hatmaker Avatar asked Oct 10 '11 17:10

Hatmaker


1 Answers

You script should start with:

#! /usr/bin/env whateverelse ...
   ^ this first one is important
like image 115
Mat Avatar answered Oct 24 '22 08:10

Mat