> >> # check if Python is called on the first line with this expression. > >> # This expression will leave lines using /usr/bin/env alone; presumably > >> # the script author knew what they were doing...) > >> first_line_re = re.compile(r'^#!(?!\s*/usr/bin/env\b).*python(\s+.*)?') > > > >Yup. Andrew, care to explain why not munging "#!/usr/bin/env python" > >lines is the right thing to do? I happen to think it's not; I think #! > >lines should always be munged (assuming this is a Python script, of > >course). > > Disagree; as the comment says, "presumably the script author knew what > they were doing..." when they put /usr/bin/env at the top. This had > to be done so that pydoc could be installed at all. Don't understand the list sentence -- what started this thread is that when pydoc is installed but there's another (older) installed python that is first on $PATH, pydoc breaks. --Guido van Rossum (home page: http://www.python.org/~guido/)
RetroSearch is an open source project built by @garambo | Open a GitHub Issue
Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo
HTML:
3.2
| Encoding:
UTF-8
| Version:
0.7.4