Fix build.bat execution in nvim, echo executed msys command
This commit is contained in:
parent
5c8954036d
commit
94fdcda5ef
@ -1,4 +1,4 @@
|
|||||||
" Plugins ==========================================================================================
|
" Plugins //////////////////////////////////////////////////////////////////////////////////////////
|
||||||
call plug#begin(stdpath('config') . '/plugged')
|
call plug#begin(stdpath('config') . '/plugged')
|
||||||
" nerdtree provides a file tree explorer
|
" nerdtree provides a file tree explorer
|
||||||
" vim-dispatch allows running async jobs in vim (i.e. builds in the background)
|
" vim-dispatch allows running async jobs in vim (i.e. builds in the background)
|
||||||
@ -42,7 +42,7 @@ call plug#begin(stdpath('config') . '/plugged')
|
|||||||
" lsp-zero end
|
" lsp-zero end
|
||||||
call plug#end()
|
call plug#end()
|
||||||
|
|
||||||
" Lua Setup ========================================================================================
|
" Lua Setup ////////////////////////////////////////////////////////////////////////////////////////
|
||||||
lua <<EOF
|
lua <<EOF
|
||||||
local leap = require('leap')
|
local leap = require('leap')
|
||||||
vim.keymap.set({'n', 'x', 'o'}, '<tab>', '<Plug>(leap-forward-to)')
|
vim.keymap.set({'n', 'x', 'o'}, '<tab>', '<Plug>(leap-forward-to)')
|
||||||
@ -63,7 +63,7 @@ lua <<EOF
|
|||||||
vim.o.shellslash = true
|
vim.o.shellslash = true
|
||||||
vim.o.makeprg = "./build.sh"
|
vim.o.makeprg = "./build.sh"
|
||||||
else
|
else
|
||||||
vim.o.makeprg = "./build.bat"
|
vim.o.makeprg = "build.bat"
|
||||||
end
|
end
|
||||||
else
|
else
|
||||||
-- vim.api.nvim_set_keymap('t', '<Esc>', '<C-\\><C-n>', {noremap = true})
|
-- vim.api.nvim_set_keymap('t', '<Esc>', '<C-\\><C-n>', {noremap = true})
|
||||||
@ -122,7 +122,7 @@ lua <<EOF
|
|||||||
formatting = cmp_format,
|
formatting = cmp_format,
|
||||||
})
|
})
|
||||||
|
|
||||||
-- LLM ===========================================================================================
|
-- LLM ///////////////////////////////////////////////////////////////////////////////////////////
|
||||||
-- local llm = require('llm')
|
-- local llm = require('llm')
|
||||||
-- llm.setup({
|
-- llm.setup({
|
||||||
-- api_token = nil, -- cf Install paragraph
|
-- api_token = nil, -- cf Install paragraph
|
||||||
@ -157,7 +157,7 @@ lua <<EOF
|
|||||||
-- enable_suggestions_on_files = "*", -- pattern matching syntax to enable suggestions on specific files, either a string or a list of strings
|
-- enable_suggestions_on_files = "*", -- pattern matching syntax to enable suggestions on specific files, either a string or a list of strings
|
||||||
-- })
|
-- })
|
||||||
|
|
||||||
-- Harpoon =======================================================================================
|
-- Harpoon ///////////////////////////////////////////////////////////////////////////////////////
|
||||||
local harpoon = require('harpoon')
|
local harpoon = require('harpoon')
|
||||||
harpoon:setup()
|
harpoon:setup()
|
||||||
vim.keymap.set("n", "<M-0>", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end)
|
vim.keymap.set("n", "<M-0>", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end)
|
||||||
@ -169,7 +169,7 @@ lua <<EOF
|
|||||||
vim.keymap.set("n", "<M-h>", function() harpoon:list():prev() end)
|
vim.keymap.set("n", "<M-h>", function() harpoon:list():prev() end)
|
||||||
vim.keymap.set("n", "<M-l>", function() harpoon:list():next() end)
|
vim.keymap.set("n", "<M-l>", function() harpoon:list():next() end)
|
||||||
|
|
||||||
-- Treesitter ====================================================================================
|
-- Treesitter ////////////////////////////////////////////////////////////////////////////////////
|
||||||
-- TODO: 2022-06-19 Treesitter is too slow on large C++ files
|
-- TODO: 2022-06-19 Treesitter is too slow on large C++ files
|
||||||
-- require('nvim-treesitter.configs').setup {
|
-- require('nvim-treesitter.configs').setup {
|
||||||
-- ensure_installed = { "c", "cpp" }, -- A list of parser names, or "all"
|
-- ensure_installed = { "c", "cpp" }, -- A list of parser names, or "all"
|
||||||
@ -193,7 +193,7 @@ lua <<EOF
|
|||||||
-- },
|
-- },
|
||||||
-- }
|
-- }
|
||||||
|
|
||||||
-- Vim Options ===================================================================================
|
-- Vim Options ///////////////////////////////////////////////////////////////////////////////////
|
||||||
vim.opt.autowrite=true -- Automatically save before cmds like :next and :prev
|
vim.opt.autowrite=true -- Automatically save before cmds like :next and :prev
|
||||||
vim.opt.colorcolumn={80, 100} -- Set a 80 and 100 char column ruler
|
vim.opt.colorcolumn={80, 100} -- Set a 80 and 100 char column ruler
|
||||||
vim.opt.completeopt={'menu', 'menuone', 'noselect'}
|
vim.opt.completeopt={'menu', 'menuone', 'noselect'}
|
||||||
@ -229,7 +229,7 @@ lua <<EOF
|
|||||||
]])
|
]])
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
" Theme ============================================================================================
|
" Theme ////////////////////////////////////////////////////////////////////////////////////////////
|
||||||
let g:gruvbox_material_background='hard'
|
let g:gruvbox_material_background='hard'
|
||||||
let g:gruvbox_material_foreground='mix'
|
let g:gruvbox_material_foreground='mix'
|
||||||
let g:gruvbox_material_disable_italic_comment=1
|
let g:gruvbox_material_disable_italic_comment=1
|
||||||
@ -253,7 +253,7 @@ let g:cpp_member_highlight = 0
|
|||||||
" (affects both C and C++ files)
|
" (affects both C and C++ files)
|
||||||
let g:cpp_simple_highlight = 1
|
let g:cpp_simple_highlight = 1
|
||||||
|
|
||||||
" Options ==========================================================================================
|
" Options //////////////////////////////////////////////////////////////////////////////////////////
|
||||||
" Show EOL type and last modified timestamp, right after the filename
|
" Show EOL type and last modified timestamp, right after the filename
|
||||||
set statusline=%<%F%h%m%r\ [%{&ff}]\ (%{strftime(\"%H:%M\ %d/%m/%Y\",getftime(expand(\"%:p\")))})%=%l,%c%V\ %P
|
set statusline=%<%F%h%m%r\ [%{&ff}]\ (%{strftime(\"%H:%M\ %d/%m/%Y\",getftime(expand(\"%:p\")))})%=%l,%c%V\ %P
|
||||||
|
|
||||||
@ -272,7 +272,7 @@ if has('mouse')
|
|||||||
set mouse=a
|
set mouse=a
|
||||||
endif
|
endif
|
||||||
|
|
||||||
" Functions ========================================================================================
|
" Functions ////////////////////////////////////////////////////////////////////////////////////////
|
||||||
" Increase font size using (Ctrl+Up Arrow) or (Ctrl+Down Arrow) if we are using
|
" Increase font size using (Ctrl+Up Arrow) or (Ctrl+Down Arrow) if we are using
|
||||||
" gvim Otherwise font size is determined in terminal
|
" gvim Otherwise font size is determined in terminal
|
||||||
nnoremap <C-Up> :silent! let &guifont = substitute(
|
nnoremap <C-Up> :silent! let &guifont = substitute(
|
||||||
@ -328,7 +328,7 @@ nnoremap <silent> <S-F5> <cmd>RemedyBGStopDebugging<cr><cr>
|
|||||||
nnoremap <silent> <F9> <cmd>RemedyBGAddBreakpointAtFile<cr><cr>
|
nnoremap <silent> <F9> <cmd>RemedyBGAddBreakpointAtFile<cr><cr>
|
||||||
nnoremap <silent> <C-F10> <cmd>RemedyBGRunToCursor<cr><cr>
|
nnoremap <silent> <C-F10> <cmd>RemedyBGRunToCursor<cr><cr>
|
||||||
|
|
||||||
" General Key Bindings =============================================================================
|
" General Key Bindings /////////////////////////////////////////////////////////////////////////////
|
||||||
" FZF Bindings
|
" FZF Bindings
|
||||||
nnoremap <leader>h <cmd>FzfLua oldfiles<cr>
|
nnoremap <leader>h <cmd>FzfLua oldfiles<cr>
|
||||||
nnoremap <leader>f <cmd>FzfLua files<cr>
|
nnoremap <leader>f <cmd>FzfLua files<cr>
|
||||||
|
@ -24,4 +24,5 @@ goto :eof
|
|||||||
set msys_env=%~1
|
set msys_env=%~1
|
||||||
for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b
|
for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b
|
||||||
|
|
||||||
|
echo [SCRIPT] Executing '%devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%"'
|
||||||
%devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%"
|
%devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%"
|
||||||
|
Loading…
Reference in New Issue
Block a user