sync of vim and sxiv

This commit is contained in:
Luke Smith 2019-11-23 15:35:16 -05:00
parent 8f608b405f
commit 2f83feeccd
No known key found for this signature in database
GPG key ID: 4C50B54A911F6252
2 changed files with 7 additions and 4 deletions

View file

@ -24,7 +24,7 @@ set bg=light
set go=a set go=a
set mouse=a set mouse=a
set nohlsearch set nohlsearch
set clipboard=unnamedplus set clipboard+=unnamedplus
" Some basics: " Some basics:
nnoremap c "_c nnoremap c "_c
@ -86,7 +86,7 @@ set clipboard=unnamedplus
" Ensure files are read as what I want: " Ensure files are read as what I want:
let g:vimwiki_ext2syntax = {'.Rmd': 'markdown', '.rmd': 'markdown','.md': 'markdown', '.markdown': 'markdown', '.mdown': 'markdown'} let g:vimwiki_ext2syntax = {'.Rmd': 'markdown', '.rmd': 'markdown','.md': 'markdown', '.markdown': 'markdown', '.mdown': 'markdown'}
map <leader>v :VimwikiIndex map <leader>v :VimwikiIndex
let g:vimwiki_list = [{'path': '~/repos/writings', 'syntax': 'markdown', 'ext': '.md'}] let g:vimwiki_list = [{'path': '~/vimwiki', 'syntax': 'markdown', 'ext': '.md'}]
autocmd BufRead,BufNewFile /tmp/calcurse*,~/.calcurse/notes/* set filetype=markdown autocmd BufRead,BufNewFile /tmp/calcurse*,~/.calcurse/notes/* set filetype=markdown
autocmd BufRead,BufNewFile *.ms,*.me,*.mom,*.man set filetype=groff autocmd BufRead,BufNewFile *.ms,*.me,*.mom,*.man set filetype=groff
autocmd BufRead,BufNewFile *.tex set filetype=tex autocmd BufRead,BufNewFile *.tex set filetype=tex
@ -95,6 +95,9 @@ set clipboard=unnamedplus
vnoremap <C-c> "+y vnoremap <C-c> "+y
map <C-p> "+P map <C-p> "+P
" Save file as sudo on files that require root permission
cnoremap w!! execute 'silent! write !sudo tee % >/dev/null' <bar> edit!
" Enable Goyo by default for mutt writting " Enable Goyo by default for mutt writting
autocmd BufRead,BufNewFile /tmp/neomutt* let g:goyo_width=80 autocmd BufRead,BufNewFile /tmp/neomutt* let g:goyo_width=80
autocmd BufRead,BufNewFile /tmp/neomutt* :Goyo | set bg=light autocmd BufRead,BufNewFile /tmp/neomutt* :Goyo | set bg=light

View file

@ -1,4 +1,4 @@
#!/bin/sh #!/usr/bin/env sh
while read file while read file
do do
case "$1" in case "$1" in
@ -23,7 +23,7 @@ do
echo -n "$file" | xclip -selection clipboard && echo -n "$file" | xclip -selection clipboard &&
notify-send "$file copied to clipboard" & ;; notify-send "$file copied to clipboard" & ;;
"Y") "Y")
echo -n "$(readlink -f "$file")" | xclip -selection clipboard && readlink -f "$file" | xclip -selection clipboard &&
notify-send "$(readlink -f "$file") copied to clipboard" & ;; notify-send "$(readlink -f "$file") copied to clipboard" & ;;
"d") "d")
[ "$(printf "No\\nYes" | dmenu -i -p "Really delete $file?")" = "Yes" ] && rm "$file" && notify-send "$file deleted." ;; [ "$(printf "No\\nYes" | dmenu -i -p "Really delete $file?")" = "Yes" ] && rm "$file" && notify-send "$file deleted." ;;