-
Hi, I am new to using neovim also asking on github ( :p ) and I was wondering if there is a way to make it so that when running code with code runner I can choose between two different types of commands. This is what I have tried to do.
It happens that at the moment of running it, the selection screen closes instantly, I tried many times but I can not get it to work. Thank you very much and apologies for the inconvenience. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Use coderunner select: |
Beta Was this translation helpful? Give feedback.
Use coderunner select:
require('code_runner.hooks.ui').select({
Marp = function()
require('code_runner').run_from_fn(
'marp --theme-set $MARPT -w -p . &$end'
)
end,
Latex = function()
hook.run({
command = 'pandoc',
args = { '$fileName', '-o', '$tmpFile', '-t pdf' },
preview_cmd = preview_cmd,
})
end,
Beamer = function()
hook.run({
command = 'pandoc',
args = { '$fileName', '-o', '$tmpFile', '-t beamer' },
preview_cmd = preview_cmd,
})
end,
Eisvogel = function()
hook.run({
command = 'bash',
args = { './build.sh' },
preview_cmd = preview_cmd,
overwrite_output = '.',
})
end,
})
for example for markdown