diff options
author | mitchell <70453897+667e-11@users.noreply.github.com> | 2008-06-24 15:48:33 -0400 |
---|---|---|
committer | mitchell <70453897+667e-11@users.noreply.github.com> | 2008-06-24 15:48:33 -0400 |
commit | 45a1f776e3c8432003e7b54432c0cbf45ec84259 (patch) | |
tree | fa323fdadcde37066156fc88d71c524eb984cfe1 /core/ext | |
parent | 0f91b311be2d598d38a66982f619432dfe61bc70 (diff) |
Fixed bug with '%' in selected text for replacing; core/ext/find.lua
Diffstat (limited to 'core/ext')
-rw-r--r-- | core/ext/find.lua | 1 | ||||
-rw-r--r-- | core/ext/mime_types.lua | 2 |
2 files changed, 3 insertions, 0 deletions
diff --git a/core/ext/find.lua b/core/ext/find.lua index 8617c274..e0491cd8 100644 --- a/core/ext/find.lua +++ b/core/ext/find.lua @@ -89,6 +89,7 @@ function find.replace(rtext) rtext = rtext:gsub('%%%%', '\\037') -- escape '%%' if find.captures then for i, v in ipairs(find.captures) do + v = v:gsub('%%', '%%%%') -- escape '%' for gsub rtext = rtext:gsub('%%'..i, v) end end diff --git a/core/ext/mime_types.lua b/core/ext/mime_types.lua index 454eec9e..dcc1e690 100644 --- a/core/ext/mime_types.lua +++ b/core/ext/mime_types.lua @@ -15,6 +15,7 @@ local languages = { javascript = 'javascript', lua = 'lua', makefile = 'makefile', + maxima = 'maxima', php = 'php', python = 'python', ragel = 'ragel', @@ -37,6 +38,7 @@ local extensions = { js = l.javascript, lua = l.lua, mak = l.makefile, makefile = l.makefile, Makefile = l.makefile, + maxima = l.maxima, php = l.php, py = l.python, pyw = l.python, rhtml = l.rhtml, |