~tomleb/repo-url.nvim

5431cbf4ecbcb9594c12f31265e2a7a41fdc5272 — Tom Lebreux 3 months ago b83a226
Try to support macOS

I don't have one so hard to tell whether it works.
1 files changed, 5 insertions(+), 1 deletions(-)

M lua/repo-url/init.lua
M lua/repo-url/init.lua => lua/repo-url/init.lua +5 -1
@@ 499,7 499,11 @@ local clipboard_url = function(url)
end

local open_url = function(url)
  vim.fn.system('xdg-open ' .. url)
  if vim.loop.os_uname().sysname == 'Darwin' then
    vim.fn.system('open' .. url)
  else
    vim.fn.system('xdg-open ' .. url)
  end
  vim.print(string.format("Opened URL '%s' in the browser", url))
end