From 37b0c79d3951304959d24218874992d125bf9854 Mon Sep 17 00:00:00 2001 From: Marius Date: Tue, 14 Sep 2010 12:20:15 +0300 Subject: beta 2010.09.14 10:28 --- scripts/context/lua/mtx-server-ctx-fonttest.lua | 2 +- scripts/context/lua/mtx-server.lua | 1 + scripts/context/lua/mtx-texworks.lua | 2 +- scripts/context/lua/mtxrun.lua | 6 ++++-- scripts/context/stubs/mswin/mtxrun.lua | 6 ++++-- scripts/context/stubs/mswin/mtxworks.exe | Bin 0 -> 6144 bytes scripts/context/stubs/unix/mtxrun | 6 ++++-- scripts/context/stubs/unix/mtxworks | 2 ++ 8 files changed, 17 insertions(+), 8 deletions(-) create mode 100644 scripts/context/stubs/mswin/mtxworks.exe create mode 100644 scripts/context/stubs/unix/mtxworks (limited to 'scripts') diff --git a/scripts/context/lua/mtx-server-ctx-fonttest.lua b/scripts/context/lua/mtx-server-ctx-fonttest.lua index 26299fc4b..d2f11ca95 100644 --- a/scripts/context/lua/mtx-server-ctx-fonttest.lua +++ b/scripts/context/lua/mtx-server-ctx-fonttest.lua @@ -11,7 +11,7 @@ dofile(resolvers.findfile("trac-lmx.lua","tex")) dofile(resolvers.findfile("font-ott.lua","tex")) dofile(resolvers.findfile("font-syn.lua","tex")) dofile(resolvers.findfile("font-mis.lua","tex")) -dofile(resolvers.findfile("font-otp.lua","tex")) +--~ dofile(resolvers.findfile("font-otp.lua","tex")) local format, gsub, concat, match, find = string.format, string.gsub, table.concat, string.match, string.find diff --git a/scripts/context/lua/mtx-server.lua b/scripts/context/lua/mtx-server.lua index 374a9e8f0..4fe0a6ac8 100644 --- a/scripts/context/lua/mtx-server.lua +++ b/scripts/context/lua/mtx-server.lua @@ -301,6 +301,7 @@ function scripts.webserver.run(configuration) local hashed = url.hashed(fullurl) local query = url.query(hashed.query) local filename = hashed.path +--~ table.print(hashed) if filename then filename = socket.url.unescape(filename) logs.simple("requested action: %s",filename) diff --git a/scripts/context/lua/mtx-texworks.lua b/scripts/context/lua/mtx-texworks.lua index 589246ccd..38a162c0e 100644 --- a/scripts/context/lua/mtx-texworks.lua +++ b/scripts/context/lua/mtx-texworks.lua @@ -25,7 +25,7 @@ local texworkininame = "texworks.ini" function scripts.texworks.start(indeed) local workname = (os.type == "windows" and "texworks.exe") or "texworks" local fullname = nil - local binpaths = file.split_path(os.getenv("PATH")) or file.split_path(os.getenv("path")) + local binpaths = file.splitpath(os.getenv("PATH")) or file.splitpath(os.getenv("path")) local usedsignal = texworkssignal local datapath = resolvers.findfile(usedsignal,"other text files") or "" if datapath ~= "" then diff --git a/scripts/context/lua/mtxrun.lua b/scripts/context/lua/mtxrun.lua index 246d08103..216a8080f 100644 --- a/scripts/context/lua/mtxrun.lua +++ b/scripts/context/lua/mtxrun.lua @@ -2505,10 +2505,11 @@ end -- todo: cache them -function url.hashed(str) +function url.hashed(str) -- not yet ok (/test?test) local s = url.split(str) local somescheme = s[1] ~= "" - if not somescheme then + local somequery = s[4] ~= "" + if not somescheme and not somequery then return { scheme = "file", authority = "", @@ -2531,6 +2532,7 @@ function url.hashed(str) end end + function url.hasscheme(str) return url.split(str)[1] ~= "" end diff --git a/scripts/context/stubs/mswin/mtxrun.lua b/scripts/context/stubs/mswin/mtxrun.lua index 246d08103..216a8080f 100644 --- a/scripts/context/stubs/mswin/mtxrun.lua +++ b/scripts/context/stubs/mswin/mtxrun.lua @@ -2505,10 +2505,11 @@ end -- todo: cache them -function url.hashed(str) +function url.hashed(str) -- not yet ok (/test?test) local s = url.split(str) local somescheme = s[1] ~= "" - if not somescheme then + local somequery = s[4] ~= "" + if not somescheme and not somequery then return { scheme = "file", authority = "", @@ -2531,6 +2532,7 @@ function url.hashed(str) end end + function url.hasscheme(str) return url.split(str)[1] ~= "" end diff --git a/scripts/context/stubs/mswin/mtxworks.exe b/scripts/context/stubs/mswin/mtxworks.exe new file mode 100644 index 000000000..2d45f2749 Binary files /dev/null and b/scripts/context/stubs/mswin/mtxworks.exe differ diff --git a/scripts/context/stubs/unix/mtxrun b/scripts/context/stubs/unix/mtxrun index 246d08103..216a8080f 100644 --- a/scripts/context/stubs/unix/mtxrun +++ b/scripts/context/stubs/unix/mtxrun @@ -2505,10 +2505,11 @@ end -- todo: cache them -function url.hashed(str) +function url.hashed(str) -- not yet ok (/test?test) local s = url.split(str) local somescheme = s[1] ~= "" - if not somescheme then + local somequery = s[4] ~= "" + if not somescheme and not somequery then return { scheme = "file", authority = "", @@ -2531,6 +2532,7 @@ function url.hashed(str) end end + function url.hasscheme(str) return url.split(str)[1] ~= "" end diff --git a/scripts/context/stubs/unix/mtxworks b/scripts/context/stubs/unix/mtxworks new file mode 100644 index 000000000..ef8f230c3 --- /dev/null +++ b/scripts/context/stubs/unix/mtxworks @@ -0,0 +1,2 @@ +#!/bin/sh +mtxrun --script texworks --start -- cgit v1.2.3