1
0
mirror of https://github.com/jbranchaud/til synced 2026-01-03 07:08:01 +00:00

Add Opening a URL to vim til.

This commit is contained in:
jbranchaud
2015-03-06 21:36:43 -06:00
parent 1e84b850d5
commit b41b025c0c
2 changed files with 12 additions and 0 deletions

11
vim/opening-a-url.md Normal file
View File

@@ -0,0 +1,11 @@
# Opening a URL
Vim makes it easy to quickly open a URL that appears in a file. Simply move
the cursor over the URL and hit `gx`. This will use your respective
operating system's *open* command (e.g. `open` for Mac OS X) to open the
URL.
One caveat is that the URL must contain the protocol/scheme. That is,
`www.duckduckgo.com` won't work, but `https://www.duckduckgo.com` will.
You can also use `gx` to open files on your system.