format with stylua
This commit is contained in:
@ -1,26 +1,22 @@
|
||||
|
||||
return {
|
||||
name = 'CMake Build for nvim',
|
||||
builder = function()
|
||||
return {
|
||||
cmd = { 'cmake' },
|
||||
args = { '--build', '.',
|
||||
'--', '-j8' },
|
||||
args = { '--build', '.', '--', '-j8' },
|
||||
cwd = 'build_nvim',
|
||||
-- components = {"on_output_parse", problem_matcher = "$gcc"}
|
||||
-- components = {'on_output_quickfix', set_diagnostics = true, open = true}
|
||||
components = { { "on_output_quickfix", open = true, open_on_match = true },
|
||||
{ 'on_output_parse', problem_matcher = '$gcc' },
|
||||
'default' },
|
||||
components = { { 'on_output_quickfix', open = true, open_on_match = true }, { 'on_output_parse', problem_matcher = '$gcc' }, 'default' },
|
||||
}
|
||||
end,
|
||||
condition = {
|
||||
callback = function(opts)
|
||||
if vim.fn.executable("cmake") == 0 then
|
||||
if vim.fn.executable('cmake') == 0 then
|
||||
return false, 'Command "cmake" not found'
|
||||
end
|
||||
if vim.fn.findfile("CMakeLists.txt", opts.dir .. ";") == "" then
|
||||
return false, "No CMakeLists.txt found"
|
||||
if vim.fn.findfile('CMakeLists.txt', opts.dir .. ';') == '' then
|
||||
return false, 'No CMakeLists.txt found'
|
||||
end
|
||||
return true
|
||||
end,
|
||||
|
Reference in New Issue
Block a user