summaryrefslogtreecommitdiff
path: root/tex/context/base/core-sys.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2012-08-25 12:53:00 +0200
committerHans Hagen <pragma@wxs.nl>2012-08-25 12:53:00 +0200
commite83414526611fee99bb66f0282fb1334c947cdab (patch)
tree13280ba974e4f9080ff7bc653857083d5818dcbc /tex/context/base/core-sys.lua
parentbc1e8c26c1c0596eb7410b522bff296fa6e7e2fc (diff)
downloadcontext-e83414526611fee99bb66f0282fb1334c947cdab.tar.gz
beta 2012.08.25 12:53
Diffstat (limited to 'tex/context/base/core-sys.lua')
-rw-r--r--tex/context/base/core-sys.lua23
1 files changed, 19 insertions, 4 deletions
diff --git a/tex/context/base/core-sys.lua b/tex/context/base/core-sys.lua
index ddcb6e938..8e4286cae 100644
--- a/tex/context/base/core-sys.lua
+++ b/tex/context/base/core-sys.lua
@@ -11,13 +11,28 @@ local suffix, basename, removesuffix = file.suffix, file.basename, file.removesu
local environment = environment
-function commands.updatefilenames(inputfilename,outputfilename)
- environment.inputfilename = inputfilename or ""
- environment.outputfilename = outputfilename or ""
- environment.jobfilename = inputfilename or tex.jobname or ""
+-- function commands.updatefilenames(inputfilename,outputfilename)
+-- --
+-- environment.jobfilename = inputfilename or tex.jobname or ""
+-- environment.jobfilesuffix = lower(suffix(environment.jobfilename))
+-- --
+-- environment.inputfilename = inputfilename or ""
+-- environment.inputfilebarename = removesuffix(basename(inputfilename))
+-- environment.inputfilesuffix = lower(suffix(inputfilename))
+-- --
+-- environment.outputfilename = outputfilename or ""
+-- end
+
+function commands.updatefilenames(jobname,inputfilename,outputfilename)
+ --
+ environment.jobfilename = jobname or inputfilename or tex.jobname or ""
environment.jobfilesuffix = lower(suffix(environment.jobfilename))
+ --
+ environment.inputfilename = inputfilename or ""
environment.inputfilebarename = removesuffix(basename(inputfilename))
environment.inputfilesuffix = lower(suffix(inputfilename))
+ --
+ environment.outputfilename = outputfilename or environment.inputfilebarename or ""
end
statistics.register("result saved in file", function()