From wolfgang.maier at biologie.uni-freiburg.de Thu Nov 12 09:14:27 2015 From: wolfgang.maier at biologie.uni-freiburg.de (Wolfgang Maier) Date: Thu, 12 Nov 2015 15:14:27 +0100 Subject: [Linux-SIG] Introducing a Python launcher for *nix? In-Reply-To: References: <20151007115202.191d05ca@limelight.wooz.org> <20151007201749.GC3938@p1otr.com> Message-ID: On 08.10.2015 01:55, Nick Coghlan wrote: > > The first motive is consistent cross platform invocation - due to the > way Python invocation on Windows is handled, commands like "python3 -m > pip" and "python3.4 -m pip" don't work, and never will, and the > differences in file system layouts exclude the use of absolute paths. > > The Python launcher for Windows *does* exist, though, so introducing a > "py" script on the *nix side of things offers the opportunity to provide > a truly cross platform Python experience modelled on the way that works: > https://docs.python.org/3/using/windows.html#python-launcher-for-windows > Then this *nix py launcher should also, like its Windows counterpart inspect .py files for presence of a shebang line and call the right interpreter based on it. Of course, on *nix systems you could make the script executable and let the shell determine the interpreter for you, but that's not cross platform compatible invocation then. In essence, you'd want everything that the Windows launcher does except for searching the registry, of course, which AFAIU you suggest replacing with user-specific and global config files, right? Best, Wolfgang