Why not just add a shebang , chmod +x and then you're done?
#!/usr/bin/python
This is sometimes what you want, but it will always look at this exact path, and won't play nicely with virtualenv/conda. #!/usr/bin/env python
This works - it will use Python found in $PATH. Unfortunately you can't add any more parameters to the interpreter.The contraption I wrote allows adding arbitrary parameters - I was burnt one too many times by Python silently buffering my debug messages, so I use it to always add "-u".
#!/usr/bin/env -S python $ARGS
For example: #!/usr/bin/env -S python -i
print("Entering interactive mode...")
I'm not sure if it works in other OS.