how to make a python or perl script portable to both linux and windows?
I was wondering how to make a python script portable to both linux and windows? One problem I see is shebang. How to write the shebang so that the script can be run on both windows and linux? Are there other problems besides shebang that I should know? Is the solution same for perl script? Thanks and regards! Windows will just ignore the shebang (which is, after all, a comment); in Windows you need to associate the .py extension to the Python executable in the registry, but you can perfectly well leave the shebang on, it will be perfectly innocuous there. There are many bits and pieces which