diff options
Diffstat (limited to 'vim/autoload/html/url.vim')
-rw-r--r-- | vim/autoload/html/url.vim | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/vim/autoload/html/url.vim b/vim/autoload/html/url.vim new file mode 100644 index 00000000..99b4409e --- /dev/null +++ b/vim/autoload/html/url.vim @@ -0,0 +1,15 @@ +" Make a bare URL into a link to itself +function! html#url#Anchor() abort + + " Yank this whole whitespace-separated word + normal! yiW + " Open a link tag + normal! i<a href=""> + " Paste the URL into the quotes + normal! hP + " Move to the end of the link text URL + normal! E + " Close the link tag + normal! a</a> + +endfunction |