Python Forum
launch .PY program Help
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
launch .PY program Help
#21
Yes, I have files associated. And no, I can't verify version switching (I'm willfully avoiding 2.x).
Reply
#22
(Oct-18-2016, 09:03 PM)nilamo Wrote: Yes, I have files associated
then it will run with or without the shebang
Recommended Tutorials:
Reply
#23
(Oct-18-2016, 08:57 PM)micseydel Wrote: Ah, I see now. Yes, it's the Python launcher doing it. Windows itself still doesn't do anything with the shebang. I did learn something new about Python's Windows launcher here though  :)

It looks like it implies that if you specify a version as you would with Unix, that it'll work on Windows. Can anyone verify that? Also, I'd be a little surprised if the Windows path works on Windows, but even if it does, it seems a Unix shebang should be used for portability.

I recently wrote a little script which I developed on my Mint 18 laptop, edited a few bits such as syntax for directory paths (and Ah yes I remember now I saved it with a .pyw extension ) i left the shebang in it and copied it to a Win10 desktop machine. It's been used for a couple of months now. it just allows the user to download a file or put a USB stick in the port and they can select the file they want to copy. The files are used by another program and the various types need to be in different directories so it means the user doesn't need to know where they go.
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Using tkinter on Windows to launch python 3 scripts Mocap 1 2,726 Jul-17-2019, 05:16 AM
Last Post: Yoriz
  Launch pdf and close on delete window event ashtona 6 5,655 Mar-22-2018, 03:04 PM
Last Post: ashtona

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020