usr / bin / env:bad interpreter Permission Denied - >如何更改fstab [英] usr/bin/env: bad interpreter Permission Denied --> how to change the fstab

查看:3021
本文介绍了usr / bin / env:bad interpreter Permission Denied - >如何更改fstab的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在Windows 7上使用cygwin运行bash脚本激活python脚本,我得到以下错误:

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。

我是一个编程的新手,所以我看了一下,我认为这意味着Python被安装在一个不能访问的目录上。但是,根据我发现,我已经尝试以下事情:

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:


  • 在fstab中更改某些内容,我的fstab文件都被注释掉,只提到默认值是什么。我不知道如何可以更改默认值。 fstab.d文件夹为空。

  • 更改#! usr / bin / env在脚本中的python行到Python的实际位置:没有工作,同样的错误

  • 向窗口的环境变量添加一个PYTHONPATH:同样的错误。 >
  • 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!

推荐答案

您的脚本应该以:

#! /usr/bin/env whateverelse ...
   ^ this first one is important

这篇关于usr / bin / env:bad interpreter Permission Denied - >如何更改fstab的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆