new gen of vimwiki script
This commit is contained in:
parent
f76327e42a
commit
0a79858b42
3 changed files with 10 additions and 10 deletions
4
gvimwiki
4
gvimwiki
|
@ -1,4 +0,0 @@
|
||||||
#!/usr/bin/bash
|
|
||||||
vim_wiki="$HOME/vimwiki/index.wiki"
|
|
||||||
# gvim wiki to scratchpad
|
|
||||||
flock -w0 ${vim_wiki} gvim ${vim_wiki}
|
|
6
tvim
6
tvim
|
@ -1,5 +1,5 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
term=default-terminal-emulator
|
TERM=$(command -v default-terminal-emulator)
|
||||||
vim=$(command -v nvim) || vim=$(command -v vim)
|
VIM=$(command -v nvim) || VIM=$(command -v vim)
|
||||||
|
|
||||||
exec $term -e $vim -c 'set mouse=a' "$@" &>/dev/null & disown
|
exec "$TERM" -e "$VIM" -c 'set mouse=a' "$@" &>/dev/null & disown
|
||||||
|
|
10
vimwiki
10
vimwiki
|
@ -1,4 +1,8 @@
|
||||||
#!/usr/bin/bash
|
#!/usr/bin/bash
|
||||||
vim_wiki="$HOME/vimwiki/index.wiki"
|
case $1 in
|
||||||
# vim wiki to scratchpad
|
-g) VIM=$(command -v gvim);;
|
||||||
default-terminal-emulator -e flock -w0 ${vim_wiki} vim ${vim_wiki}
|
-n) VIM=$(command -v nvim) || VIM=$(command -v vim);;
|
||||||
|
*) VIM=$(command -v tvim);;
|
||||||
|
esac
|
||||||
|
VIMWIKI_RC="$HOME/vimwiki/.vimwikirc"
|
||||||
|
exec flock -w0 "$VIMWIKI_RC" "$VIM" -c "source $VIMWIKI_RC"
|
||||||
|
|
Loading…
Reference in a new issue