#! /usr/bin/env considered harmful - Programming On Unix
Users browsing this thread: 3 Guest(s)
|
|||
i) correct interpreter indeed. If you are on a shared server and are setting up a cron job that uses the absolute path to the python binary /usr/bin/python2.7, can you even still be sure that the executable is the one intended to complete the job? Or does shebanging absolutely give you checksumming powers?
ii) https://www.python.org/dev/peps/pep-0370/ iii) byoi(nterpreter) iv) no flags? fine, don't use shebang on interpreted scripts. $ /usr/bin/python2.7 -RE ~/myscript v) manage $PATH -- I fail to see the problem vi) I feel like #!/usr/bin/env is suitable in the most properly configured environments; and in that case, more suited Good read though :) |
|||
Messages In This Thread |
#! /usr/bin/env considered harmful - by jkl - 14-09-2016, 12:27 PM
RE: #! /usr/bin/env considered harmful - by venam - 14-09-2016, 01:04 PM
RE: #! /usr/bin/env considered harmful - by z3bra - 14-09-2016, 01:36 PM
RE: #! /usr/bin/env considered harmful - by josuah - 14-09-2016, 05:34 PM
RE: #! /usr/bin/env considered harmful - by robotchaos - 14-09-2016, 05:35 PM
RE: #! /usr/bin/env considered harmful - by jkl - 14-09-2016, 08:13 PM
RE: #! /usr/bin/env considered harmful - by pranomostro - 14-09-2016, 08:59 PM
RE: #! /usr/bin/env considered harmful - by robotchaos - 14-09-2016, 11:27 PM
RE: #! /usr/bin/env considered harmful - by z3bra - 15-09-2016, 05:40 AM
RE: #! /usr/bin/env considered harmful - by TheAnachron - 15-09-2016, 06:18 AM
RE: #! /usr/bin/env considered harmful - by z3bra - 15-09-2016, 09:14 AM
RE: #! /usr/bin/env considered harmful - by Halfwit - 14-10-2016, 11:51 PM
|