Reputation: 413
I have a program called ftpgrab.py. At the command prompt to run it I type:
c:\path\to\python\dir\python.exe ftpgrab.py
Is there a way on Windows 8 to create an icon which I can double-click to run this?
Upvotes: 0
Views: 81
Reputation: 77357
Assuming that you used one of the standard installers for python on windows, .py is already registered and it should just work. Copy it to your desktop and double-click. A console running the program should appear and run as normal. Its still a console app - the the customer wants a gui app, that's a different story.
btw, you shouldn't even have to type c:\path\to\python\dir\python.exe ftpgrab.py
, just a plain ftpgrab.py
or ftpgrab
should do.
Upvotes: 1
Reputation: 64148
You can either create a batch file that will launch the program, or use something like pyinstaller to transform your script into an executable that can be run directly.
Upvotes: 4
Reputation: 34027
foo.bat
;foo.bat
...Upvotes: 2