Wikia

Vim Tips Wiki

Script:293

Talk0
1,613pages on
this wiki
Revision as of 09:33, February 18, 2013 by 194.209.145.200 (Talk)

Improvements

Often I got urls in the format (http://www.vim.org) or (see http://www.vim.org). Urls with braces around or a brace at the end are not correctly recognized.

Therefore I added following lines to utl.vim around line 407:

   call Utl_trace("- end getting URL under cursor.",1,-1) 
   let tmpurl = matchstr(url, '^[(]\?.*[)]\+$')
   if empty(tmpurl)
     return url
   else
     call Utl_trace("- found braces around url, removing.",1,-1) 
     return substitute(url, '^[(]\?\(.*\)[)]\+$', '\1', 'g')
   endif

Around Wikia's network

Random Wiki