random script dump
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

vimwiki 426B

1234567891011121314151617
  1. #!/usr/bin/zsh
  2. INDEX="$HOME/vimwiki/index.md"
  3. WIKIOPTS="[{'path': '$HOME/vimwiki/', 'syntax': 'markdown', 'ext': '.md'}]"
  4. VIMOPTS=(
  5. '-c' 'set titlestring=vimwiki'
  6. '-c' "let g:vimwiki_list = $WIKIOPTS"
  7. '-c' 'packadd vimwiki'
  8. '-c' "e $INDEX"
  9. )
  10. case $1 in
  11. -g) vimbin=$(command -v gvim);;
  12. -n) vimbin=$(command -v vim);;
  13. *) vimbin=$(command -v tvim);;
  14. esac
  15. exec flock -w0 $INDEX $vimbin ${VIMOPTS[@]}