experimental dokuwiki vim
This commit is contained in:
31
vim/vimdw
Executable file
31
vim/vimdw
Executable file
@@ -0,0 +1,31 @@
|
||||
#!/bin/bash
|
||||
function helpexit() {
|
||||
cat <<EOF
|
||||
Edit a file with dokuwiki syntax.
|
||||
|
||||
In insert mode:
|
||||
Ctrl-w h1-6: ====== headings ======
|
||||
Ctrl-w bb/ii/uu: **bold** //italic// __underline__
|
||||
Ctrl-w dd: <del>deleted</del>
|
||||
Ctrl-w l: [[URL|Title]]
|
||||
Ctrl-w f: ((footnote))
|
||||
Ctrl-w i/im: {{ wiki:image.png?width }} (can be url)
|
||||
Ctrl-w -: * unordered
|
||||
Ctrl-w 1: - ordered list
|
||||
Ctrl-w , and .: de-indent and indent
|
||||
Ctrl-w c: <code bash file.sh>\n</code>
|
||||
|
||||
normal mode:
|
||||
Space toggles <todo>
|
||||
|
||||
EOF
|
||||
exit
|
||||
}
|
||||
[[ -z "$1" ]] && helpexit
|
||||
[[ "$1" = "-h" ]] && helpexit
|
||||
|
||||
case $OSTYPE in
|
||||
darwin*) LIB=$( dirname $( realpath $0 ) )/dokuwiki.vim ;;
|
||||
*) LIB=$( dirname $( readlink -f $0 ) )/dokuwiki.vim ;;
|
||||
esac
|
||||
vim -S "$LIB" "$@"
|
||||
Reference in New Issue
Block a user