Fix local templates being linked and add markdown preview plugin to nvim
This commit is contained in:
@@ -178,7 +178,8 @@ function! MapPlugins()
|
||||
map <localleader>rr :RustRun<CR>
|
||||
|
||||
" - Markdown -
|
||||
map <localleader>v :LivedownToggle<CR>
|
||||
" map <localleader>v :LivedownToggle<CR>
|
||||
nmap <localleader>v <Plug>MarkdownPreviewToggle
|
||||
endfunction
|
||||
|
||||
augroup Plugin_Mappings
|
||||
|
||||
@@ -173,6 +173,8 @@ Plug 'sophacles/vim-processing'
|
||||
|
||||
" - Markdown -
|
||||
" Plug 'shime/vim-livedown'
|
||||
" Plug 'iamcco/markdown-preview.nvim', { 'do': 'cd app && npx --yes yarn install' }
|
||||
Plug 'iamcco/markdown-preview.nvim', { 'do': { -> mkdp#util#install() }, 'for': ['markdown', 'vim-plug']}
|
||||
|
||||
|
||||
" --- Icons ---
|
||||
|
||||
@@ -322,4 +322,6 @@ let g:rust_fold = 2
|
||||
let g:processing_fold = 1
|
||||
|
||||
" - Markdown -
|
||||
" Livedown
|
||||
let g:livedown_open = 1
|
||||
" Markdown Preview
|
||||
|
||||
+2
-4
@@ -238,13 +238,11 @@ function link_dotfiles {
|
||||
done
|
||||
for file in $local_home_templates; do
|
||||
if [[ -f ./local-templates/$file || -d ./local-templates/$file ]]; then
|
||||
if [[ -L "$HOME/.$file" ]]; then
|
||||
echo "Skipping: $file because ~/.$file already linked"
|
||||
elif [[ -f $HOME/.$file || -d $HOME/.$file ]]; then
|
||||
if [[ -f $HOME/.$file || -d $HOME/.$file ]]; then
|
||||
echo "Skipping: $file because ~/.$file already exists"
|
||||
else
|
||||
echo "Copying: $file ($config_dir/local-templates/$file -> ~/.$file)"
|
||||
ln -s $config_dir/local-templates/$file $HOME/.$file
|
||||
cp $config_dir/local-templates/$file $HOME/.$file
|
||||
fi
|
||||
fi
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user