Running python script from command line on Windows

I am trying to run SnakeFood to parse a python project. I am on a Windows computer, and so far I have been able to figure out how:

  • install Tortoise for Mercurial to download SnakeFood code from the site.
  • set the "Path" parameter to the path to the python path from the command line so that I can make python setup.py install and get snakefood to go to the "site-packages" folder

Now the documentation says nothing more, and not: sfood /path/to/my/project

I can not get this command to work. What am I missing?

+4
source share
3 answers

Will this work?

 python "DriveLetter:\path\to\sfood.py" "DriveLetter:\path\to\your\project" 
+4
source

Given that the documentation says "sfood / path / to / my / project", it most likely assumes a * nix environment. This leads me to speculate that sfood probably has a shebang line.

On Windows, you will probably need to use "python sfood". If "sfood" is not in your PATH, you need to write the full path, not just "sfood".

+1
source

I was able to solve this problem on my Windows 7 machine with Python 2.7.3 installed:

 C:\> cd \path\to\snakefood\installation\folder C:\path\to\snakefood\installation\folder> python setup.py install ... C:\path\to\snakefood\installation\folder> cd C:\Python27\Scripts C:\Python27\Scripts> python sfood \path\to\my\project ... 
+1
source

All Articles