Re: Python Script Hashplings

2013-07-26 Thread Devyn Collier Johnson
On 07/26/2013 10:14 AM, Chris Angelico wrote: On Fri, Jul 26, 2013 at 2:53 PM, MRAB wrote: If you want to test what would happen if that version wasn't installed, set the shebang line to a future version, such as Python 3.4. I doubt you have that installed! :-) Be careful, some people DO have

Re: Python Script Hashplings

2013-07-26 Thread Ben Finney
Tim Golden writes: > Devyn, I'm not a *nix person so someone can point out if I'm wrong, > but my understanding is that the shebang line (or whatever you want to > call it) just tells the shell: run this command to run this file. So > you can put "#!/usr/bin/fish-and-chips" as the first line and

RE: Python Script Hashplings

2013-07-26 Thread Prasad, Ramit
Devyn Collier Johnson wrote: > Thanks Matthew Lefavor! But specifically, why use "#!/usr/bin/env python3" > instead of > "#!/usr/bin/python3"? > > Mahalo, > > DCJ I believe this will work on Windows for Python 3.3+ and also with virtualenv. https://pypi.python.org/pypi/virtualenv Virtualenv i

Re: Python Script Hashplings

2013-07-26 Thread Matthew Lefavor
> > > Thanks Matthew Lefavor! But specifically, why use "#!/usr/bin/env python3" > instead of "#!/usr/bin/python3"? > The "env" program looks up its argument in the current $PATH environment variable, and then executes that. This means you aren't necessarily tied to /usr/bin/python3. It makes thin

Re: Python Script Hashplings

2013-07-26 Thread Chris Angelico
On Fri, Jul 26, 2013 at 2:53 PM, MRAB wrote: > If you want to test what would happen if that version wasn't installed, > set the shebang line to a future version, such as Python 3.4. I doubt > you have that installed! :-) Be careful, some people DO have a python3.4 binary :) Go for 3.5 for a bit

Re: Python Script Hashplings

2013-07-26 Thread MRAB
On 26/07/2013 11:43, Chris Angelico wrote: On Fri, Jul 26, 2013 at 11:37 AM, Devyn Collier Johnson wrote: On 07/25/2013 09:54 AM, MRAB wrote: On 25/07/2013 14:42, Devyn Collier Johnson wrote: If I execute a Python3 script with this haspling (#!/usr/bin/python3.3) and Python3.3 is not insta

Re: Python Script Hashplings

2013-07-26 Thread Tim Golden
On 26/07/2013 11:37, Devyn Collier Johnson wrote: > > On 07/25/2013 09:54 AM, MRAB wrote: >> On 25/07/2013 14:42, Devyn Collier Johnson wrote: >>> If I execute a Python3 script with this haspling (#!/usr/bin/python3.3) >>> and Python3.3 is not installed, but Python3.2 is installed, would the >>> s

Re: Python Script Hashplings

2013-07-26 Thread Chris Angelico
On Fri, Jul 26, 2013 at 11:37 AM, Devyn Collier Johnson wrote: > > On 07/25/2013 09:54 AM, MRAB wrote: >> >> On 25/07/2013 14:42, Devyn Collier Johnson wrote: >>> >>> If I execute a Python3 script with this haspling (#!/usr/bin/python3.3) >>> and Python3.3 is not installed, but Python3.2 is instal

Re: Python Script Hashplings

2013-07-26 Thread Devyn Collier Johnson
On 07/25/2013 10:01 AM, Matthew Lefavor wrote: The answer is "probably not." If you just want to use the latest version of Python 3 you have installed on your system, use: "#!/usr/bin/python3". When you use the specific minor version numbers, they point to that specific minor version. Actual

Re: Python Script Hashplings

2013-07-26 Thread Devyn Collier Johnson
On 07/25/2013 09:54 AM, MRAB wrote: On 25/07/2013 14:42, Devyn Collier Johnson wrote: If I execute a Python3 script with this haspling (#!/usr/bin/python3.3) and Python3.3 is not installed, but Python3.2 is installed, would the script still work? Would it fall back to Python3.2? Why don't you

Re: Python Script Hashplings

2013-07-25 Thread Matthew Lefavor
The answer is "probably not." If you just want to use the latest version of Python 3 you have installed on your system, use: "#!/usr/bin/python3". When you use the specific minor version numbers, they point to that specific minor version. Actually, the preferred shebang line is of the form: "#!/us

Re: Python Script Hashplings

2013-07-25 Thread MRAB
On 25/07/2013 14:42, Devyn Collier Johnson wrote: If I execute a Python3 script with this haspling (#!/usr/bin/python3.3) and Python3.3 is not installed, but Python3.2 is installed, would the script still work? Would it fall back to Python3.2? Why don't you try it? I hope Dihedral is listenin