From f220cac192399c74d0309f75d8e3963ab7702cd6 Mon Sep 17 00:00:00 2001 From: dvs1 Date: Mon, 28 Oct 2024 13:37:20 +1000 Subject: Fix the PHP example. --- PolygLua.lua | 2 ++ test_.lua | 6 ++---- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/PolygLua.lua b/PolygLua.lua index ee775eb..727e62c 100755 --- a/PolygLua.lua +++ b/PolygLua.lua @@ -209,6 +209,8 @@ __ = function(c) exe.scriptFile = os.tmpname() D('Creating temporary script file at ' .. exe.scriptFile) exe.cmd = exe.cmd .. l:sub(3) .. ' ' .. exe.scriptFile .. ' ; ' + -- PHP wants this to be executable. + __('chmod u+x ' .. exe.scriptFile) end exe.script = exe.script .. l .. '\n' else diff --git a/test_.lua b/test_.lua index a589a00..80e1786 100755 --- a/test_.lua +++ b/test_.lua @@ -121,11 +121,9 @@ __[[#!/usr/bin/perl ]]:log():show():Do() print('') --- No idea why this isn't working. -__[[#!/usr/bin/php +__[[#!/usr/bin/env php + print("G'day world from php.\n"); ]]:log():show():Do() print('') -- cgit v1.1