dotfiles

Cross platform dotfiles for linux, mac and windows
git clone git@getsh.org:dotfiles.git
Log | Files | Refs

commit 442b1242c6d450bdca1dc3c697b18e98e261bc7b
parent 2a987e34b8d4822972bb571dbff9c903ee56e17d
Author: bharatvaj.ph <bharatvaj.ph@zohocorp.com>
Date:   Wed, 27 Apr 2022 19:28:58 +0530

Properly setup gvim in windows

Diffstat:
M.config/cmd/aliases.cmd | 1+
M.config/cmd/profile.cmd | 3+++
A.config/cmd/setup.cmd | 6++++++
M.config/cmd/setup.ps1 | 4+---
A.config/vim/gvimrc | 2++
M.config/vim/vimrc | 15++++++++-------
6 files changed, 21 insertions(+), 10 deletions(-)

diff --git a/.config/cmd/aliases.cmd b/.config/cmd/aliases.cmd @@ -2,4 +2,5 @@ doskey v=vim $* doskey vi=vim $* doskey n=nvim $* doskey g=git $* +doskey e=%EDITOR% $* doskey l=%USERPROFILE%\.config\cmd\lfcd.cmd diff --git a/.config/cmd/profile.cmd b/.config/cmd/profile.cmd @@ -9,4 +9,7 @@ set XDG_CONFIG_HOME=%USERPROFILE%\.config set XDG_DATA_HOME=%USERPROFILE%\.local\share set XDG_CACHE_HOME=%USERPROFILE%\.cache +set MYVIMRC=%XDG_CONFIG_HOME%\vim\vimrc +set VIMINIT=source $MYVIMRC + %USERPROFILE%\.config\cmd\aliases.cmd diff --git a/.config/cmd/setup.cmd b/.config/cmd/setup.cmd @@ -0,0 +1,6 @@ +powershell setup.ps1 + +# Apply config patches +xcopy %USERPROFILE%\.config\cmd\patch %USERPROFILE%\ /S /E + +mklink %USERPROFILE%\_vimrc %USERPROFILE%\.config\vim\vimrc diff --git a/.config/cmd/setup.ps1 b/.config/cmd/setup.ps1 @@ -1,10 +1,8 @@ Set-ExecutionPolicy RemoteSigned -scope CurrentUser -# TODO Handle Admin user check +#TODO Make this work for Administrator accounts Invoke-Expression (New-Object System.Net.WebClient).DownloadString('https://get.scoop.sh') # Install the absolute essentials scoop install $(gc ~/.config/cmd/packages.txt) -# Apply config patches -xcopy $Env:USERPROFILE\.config\cmd\patch $Env:USERPROFILE\ /S /E diff --git a/.config/vim/gvimrc b/.config/vim/gvimrc @@ -0,0 +1,2 @@ +set guifont=Fira\ Code\ SemiBold +set guioptions= diff --git a/.config/vim/vimrc b/.config/vim/vimrc @@ -94,14 +94,15 @@ augroup user_cmds autocmd VimEnter * call timer_start(20, function('s:load_plugins')) augroup END +if has("gui") + source $XDG_CONFIG_HOME/vim/gvimrc +endif + if has("win32") - if executable("pwsh") - set shell=pwsh - set shellcmdflag=-ExecutionPolicy\ RemoteSigned\ -Command - set shellquote=\" - " shellxquote must be a literal space character. - set shellxquote= - endif + set shell=cmd + set shellquote=\" + " shellxquote must be a literal space character. + set shellxquote= endif set path+=**