From 6cfb5a3d7dcacfda69498a20295d6acf2203bb09 Mon Sep 17 00:00:00 2001 From: doyle Date: Sat, 18 Jun 2022 01:58:55 +1000 Subject: [PATCH] stuff --- Installer/os_nvim_init.vim | 15 +++++++++++++++ win_install.bat | 7 ++++--- 2 files changed, 19 insertions(+), 3 deletions(-) diff --git a/Installer/os_nvim_init.vim b/Installer/os_nvim_init.vim index fbf2e98..c7bf734 100644 --- a/Installer/os_nvim_init.vim +++ b/Installer/os_nvim_init.vim @@ -7,6 +7,7 @@ call plug#begin(stdpath('config') . '/plugged') Plug 'https://github.com/Tetralux/odin.vim' Plug 'https://github.com/morhetz/gruvbox' Plug 'https://github.com/neovim/nvim-lspconfig' + Plug 'https://github.com/tpope/vim-dispatch' call plug#end() " Setup LSP @@ -42,6 +43,7 @@ set number " Show line numbers set relativenumber " Show relative line numbers set shiftwidth=4 " Number of spaces for each autoindent step set textwidth=80 " On format, format to 80 char long lines +set nohlsearch " 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 guifont=JetBrains_Mono:h9,Consolas:h9,InputMonoCondensed:h9 @@ -160,3 +162,16 @@ set errorformat+=\\\ %#%s\ :\ error\ %m " MSVC: link.exe, set errorformat+=\\\ %#%s\ :\ fatal\ error\ %m " MSVC: link.exe, fatal errors is badly implemented set errorformat+=\\\ %#%f(%l\\\,%c-%*[0-9]):\ %#%t%[A-z]%#\ %m " MSVC: HLSL fxc.exe set errorformat+=%\\%%(CTIME%\\)%\\@=%m " ctime.exe -stats + +" Vim Dispatch +" ============================================================================== +let s:running_windows = has("win16") || has("win32") || has("win64") +if s:running_windows + set makeprg=build + nnoremap :Make ./build.bat +else + " Set vim terminal to enter normal mode using escape like normal vim behaviour + tnoremap + nnoremap :Make ./build.sh + set makeprg=./build.sh +endif diff --git a/win_install.bat b/win_install.bat index 47c8f9f..818ba67 100644 --- a/win_install.bat +++ b/win_install.bat @@ -715,9 +715,10 @@ REM ---------------------------------------------------------------------------- REM ctags: C/C++ code annotation generator REM scanmapset: Bind capslock to escape via registry REM uncap: Bind capslock to escape via run-time program -call :CopyAndAlwaysOverwriteFile "!installer_dir!\win_scanmapset.exe" "!bin_dir!\scanmapset.exe" || exit /B -call :CopyAndAlwaysOverwriteFile "!installer_dir!\win_uncap.exe" "!bin_dir!\uncap.exe" || exit /B -call :CopyAndAlwaysOverwriteFile "!installer_dir!\os_clang_format_style_file" "!home_dir!\_clang-format" || exit /B +call :CopyAndAlwaysOverwriteFile "!installer_dir!\win_clang_merge_compilation_command_files.bat" "!bin_dir!\clang_merge_compilation_command_files.bat" || exit /B +call :CopyAndAlwaysOverwriteFile "!installer_dir!\win_scanmapset.exe" "!bin_dir!\scanmapset.exe" || exit /B +call :CopyAndAlwaysOverwriteFile "!installer_dir!\win_uncap.exe" "!bin_dir!\uncap.exe" || exit /B +call :CopyAndAlwaysOverwriteFile "!installer_dir!\os_clang_format_style_file" "!home_dir!\_clang-format" || exit /B REM ------------------------------------------------------------------------ REM MobaXTerm