summaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2010-04-29 22:30:00 +0200
committerHans Hagen <pragma@wxs.nl>2010-04-29 22:30:00 +0200
commitf9ccde99028609a89c3a933a9ec761cb2f7d0815 (patch)
treeb2f0ace88743565a4a4cb0b4a1e7beed6005eb08 /scripts
parentc0b0ae6f764e245be857989068567cf88dc75fe9 (diff)
downloadcontext-f9ccde99028609a89c3a933a9ec761cb2f7d0815.tar.gz
beta 2010.04.29 22:30
Diffstat (limited to 'scripts')
-rw-r--r--scripts/context/lua/mtxrun.lua7
-rw-r--r--scripts/context/stubs/mswin/mtxrun.lua7
-rwxr-xr-xscripts/context/stubs/unix/mtxrun7
3 files changed, 21 insertions, 0 deletions
diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua
index f79439e07..3c72f59d1 100644
--- a/scripts/context/lua/mtxrun.lua
+++ b/scripts/context/lua/mtxrun.lua
@@ -12123,6 +12123,13 @@ end
function runners.execute_ctx_script(filename)
local arguments = environment.arguments_after
local fullname = runners.find_mtx_script(filename) or ""
+ if file.extname(fullname) == "cld" then
+ -- handy in editors where we force --autopdf
+ logs.simple("running cld script: %s",filename)
+ table.insert(arguments,1,fullname)
+ table.insert(arguments,"--autopdf")
+ fullname = runners.find_mtx_script("context") or ""
+ end
-- retry after generate but only if --autogenerate
if fullname == "" and environment.argument("autogenerate") then -- might become the default
instance.renewcache = true
diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua
index f79439e07..3c72f59d1 100644
--- a/scripts/context/stubs/mswin/mtxrun.lua
+++ b/scripts/context/stubs/mswin/mtxrun.lua
@@ -12123,6 +12123,13 @@ end
function runners.execute_ctx_script(filename)
local arguments = environment.arguments_after
local fullname = runners.find_mtx_script(filename) or ""
+ if file.extname(fullname) == "cld" then
+ -- handy in editors where we force --autopdf
+ logs.simple("running cld script: %s",filename)
+ table.insert(arguments,1,fullname)
+ table.insert(arguments,"--autopdf")
+ fullname = runners.find_mtx_script("context") or ""
+ end
-- retry after generate but only if --autogenerate
if fullname == "" and environment.argument("autogenerate") then -- might become the default
instance.renewcache = true
diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun
index f79439e07..3c72f59d1 100755
--- a/scripts/context/stubs/unix/mtxrun
+++ b/scripts/context/stubs/unix/mtxrun
@@ -12123,6 +12123,13 @@ end
function runners.execute_ctx_script(filename)
local arguments = environment.arguments_after
local fullname = runners.find_mtx_script(filename) or ""
+ if file.extname(fullname) == "cld" then
+ -- handy in editors where we force --autopdf
+ logs.simple("running cld script: %s",filename)
+ table.insert(arguments,1,fullname)
+ table.insert(arguments,"--autopdf")
+ fullname = runners.find_mtx_script("context") or ""
+ end
-- retry after generate but only if --autogenerate
if fullname == "" and environment.argument("autogenerate") then -- might become the default
instance.renewcache = true