Use consistent path for all *.py scripts
Review Request #129 - Created Jan. 28, 2011 and submitted
Merov Linden | Reviewers | ||
https://merov_linden@bitbucket.org/merov_linden/viewer-development-storm-937 | viewer | ||
STORM-937 | |||
None | viewer-development |
Simple consistency change, using "#!/usr/bin/python" in all python script.
Pulled into a test repo and build successfully on all platforms on TC so I guess no bad surprise here.
Looks like a good consistency improvement.
Covers all occurrences of the variant with env, so should be fine. As currently both variants are present, choosing only one of them (no matter which) should not hinder anyone who can already use the scripts today (except if they only used scripts with one of the variants, up to now.) If we later discover that using the other variant would bring any advantage (like, allowing to call the script directly rather than prepending the interpreter command) we can always make that change later.
Posted (Jan. 31, 2011, 6:27 a.m.)
Why didn't you choose "!/usr/bin/env python"? It seems more flexible.
Posted (Jan. 31, 2011, 11:47 a.m.)
I would much prefer that we put the /usr/bin/env python form, since env can find whichever python is currently set up, including someone that has it in /usr/local/bin, or wherever they've chosen. Env is more likely to be found in /usr/bin than python is. So I'd like to see this change made the opposite way.
Review request changed
Updated (Feb. 9, 2011, 3:33 p.m.)
-
- added Diff r2
Took comments into account: - Changed to use the #!/usr/bin/env python shebang line - Add license info to python files that were missing one - Reformatted some license header for consistency - Updated wiki http://wiki.secondlife.com/wiki/Coding_standard#Python to make those aspects (shebang and licensing) clear
Those changes look good. For future reference, there's no reason to add date ranges in Copyright headers - the only year needed is the year of first publication. Adding additional years is not needed and serves no purpose.
Review request changed
Updated (Feb. 11, 2011, 6:23 p.m.)
-
- added Diff r3
The previous change revealed issues on Windows, namely, the use of the commands module on Windows in llversion.py. I changed that to use subprocess instead and cleaned up old svn functions rather than "fixing" them.
Other reviews