diff options
author | Minijackson <minijackson@riseup.net> | 2024-05-21 22:24:21 +0200 |
---|---|---|
committer | Minijackson <minijackson@riseup.net> | 2024-05-21 22:24:21 +0200 |
commit | 0806dd055c2855a0611c8857a19cdab566909442 (patch) | |
tree | 925e6a7ccb34abd0508ca91fcee65e34a3beabca /common | |
parent | 13307090446525b499e9c15781b426dc27b3e7fe (diff) | |
download | nixos-config-reborn-0806dd055c2855a0611c8857a19cdab566909442.tar.gz nixos-config-reborn-0806dd055c2855a0611c8857a19cdab566909442.zip |
nixvim: use vim.ui.open for :Browse
Diffstat (limited to 'common')
-rw-r--r-- | common/nixvim.nix | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/common/nixvim.nix b/common/nixvim.nix index 7735a75..ba6a8c5 100644 --- a/common/nixvim.nix +++ b/common/nixvim.nix | |||
@@ -545,14 +545,8 @@ in | |||
545 | 545 | ||
546 | 546 | ||
547 | -- For fugitive's :GBrowse | 547 | -- For fugitive's :GBrowse |
548 | |||
549 | vim.api.nvim_create_user_command("Browse", function(opts) | 548 | vim.api.nvim_create_user_command("Browse", function(opts) |
550 | local Job = require('plenary.job') | 549 | vim.ui.open(opts.args) |
551 | |||
552 | Job:new({ | ||
553 | command = 'xdg-open', | ||
554 | args = { opts.args }, | ||
555 | }):start() | ||
556 | end, { nargs = 1 }) | 550 | end, { nargs = 1 }) |
557 | ''; | 551 | ''; |
558 | }; | 552 | }; |