Skip to content

Commit

Permalink
Fix gx README.md examples
Browse files Browse the repository at this point in the history
  • Loading branch information
jamylak authored and chrisgrieser committed Apr 7, 2024
1 parent 6cefba2 commit 32359b9
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -468,7 +468,7 @@ vim.keymap.set("n", "gx", function()
require("various-textobjs").url()
local foundURL = vim.fn.mode():find("v")
if foundURL then
u.normal('"zy')
vim.cmd.normal('"zy')
local url = vim.fn.getreg("z")
openURL(url)
else
Expand All @@ -484,7 +484,7 @@ vim.keymap.set("n", "gx", function()
-- select one, use a plugin like dressing.nvim for nicer UI for
-- `vim.ui.select`
vim.ui.select(urls, { prompt = "Select URL:" }, function(choice)
if choice then openURL(url) end
if choice then openURL(choice) end
end)
end
end, { desc = "URL Opener" })
Expand Down

0 comments on commit 32359b9

Please sign in to comment.