Hi,

Am 07/28/2016 um 09:21 AM schrieb Steven D'Aprano:
But Perl has a feature that
if you tell it to run a file with a hashbang line, it will call the given
executable to run that file. That's now been improved to recognise Perl6 as an
external executable, instead of trying to run it as Perl 5 code.

Should Python do something similar? At least for Python 2/3 code?

Do you mean something like

#!/usr/bin/env python2.7

# here comes Python 3 code

should be run using python3, if installed? Why not just put the python3 executable into the hashbang line?

Lutz


--
https://www.lhorn.de/
https://emailselfdefense.fsf.org/de/
--
https://mail.python.org/mailman/listinfo/python-list

Reply via email to