Skip to content

Instantly share code, notes, and snippets.

@yjsoon
Created August 26, 2012 04:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save yjsoon/3474117 to your computer and use it in GitHub Desktop.
Save yjsoon/3474117 to your computer and use it in GitHub Desktop.
vim search Dash
" Search Dash for word under cursor
function! SearchDash()
let s:browser = "/usr/bin/open"
let s:wordUnderCursor = expand("<cword>")
let s:url = "dash://".s:wordUnderCursor
let s:cmd ="silent ! " . s:browser . " " . s:url
execute s:cmd
redraw!
endfunction
map <leader>d :call SearchDash()<CR>
@yjsoon
Copy link
Author

yjsoon commented Aug 27, 2012

More advanced version here: https://gist.github.com/3485271

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment