This commit is contained in:
commit
b13f4b53ff
|
@ -0,0 +1,6 @@
|
|||
{
|
||||
"Alt-/": "lua:comment.comment",
|
||||
"Alt-l": "lua:initlua.ixio",
|
||||
"CtrlR": "lua:initlua.runme",
|
||||
"CtrlUnderscore": "lua:comment.comment"
|
||||
}
|
|
@ -0,0 +1,29 @@
|
|||
local config = import("micro/config")
|
||||
local shell = import("micro/shell")
|
||||
|
||||
function runme(bp)
|
||||
local buf = bp.Buf -- The current buffer
|
||||
buf:Save()
|
||||
if buf:FileType() == "python" then
|
||||
shell.RunInteractiveShell("python3 " .. buf.Path, true, false)
|
||||
elseif buf:FileType() == "myrddin" then
|
||||
shell.RunInteractiveShell("mbld -R " .. buf.Path, true, false)
|
||||
elseif buf:FileType() == "picolisp" then
|
||||
shell.RunInteractiveShell("pil " .. buf.Path .. " +", true, false)
|
||||
elseif buf:FileType() == "verifpal" then
|
||||
shell.RunInteractiveShell("verifpal verify " .. buf.Path, true, false)
|
||||
elseif buf:FileType() == "ruby" then
|
||||
shell.RunInteractiveShell("ruby " .. buf.Path, true, false)
|
||||
elseif buf:FileType() == "d" then
|
||||
shell.RunInteractiveShell("dmd -run " .. buf.Path, true, false)
|
||||
end
|
||||
end
|
||||
function ixio(bp)
|
||||
local buf = bp.Buf
|
||||
buf:Save()
|
||||
shell.RunInteractiveShell("curl -F 'f=@" .. buf.Path .. "' pb1n.de", true, false)
|
||||
end
|
||||
function init()
|
||||
config.TryBindKey("CtrlR", "lua:initlua.runme", true)
|
||||
config.TryBindKey("Alt-l", "lua:initlua.ixio", true)
|
||||
end
|
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
"*.l": {
|
||||
"autoclose": false,
|
||||
"autoident": true,
|
||||
"filetype": "picolisp",
|
||||
"matchbrace": true,
|
||||
"matchbraceleft": true,
|
||||
"tabsize": 3,
|
||||
"tabstospaces": true
|
||||
},
|
||||
"*.vp": {
|
||||
"commenttype": "// %s",
|
||||
"filetype": "verifpal"
|
||||
},
|
||||
"autoclose": false,
|
||||
"cursorline": false,
|
||||
"rmtrailingws": true,
|
||||
"ruler": false
|
||||
}
|
Loading…
Reference in New Issue