From 17f0b61a7772e92dbd1daf35183b798377a5025c Mon Sep 17 00:00:00 2001 From: Gustaf Rydholm Date: Wed, 3 Jan 2024 00:01:16 +0100 Subject: Set oil to float --- fnl/plugins/editor/oil.fnl | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/fnl/plugins/editor/oil.fnl b/fnl/plugins/editor/oil.fnl index 1f09ec3..a15c22e 100644 --- a/fnl/plugins/editor/oil.fnl +++ b/fnl/plugins/editor/oil.fnl @@ -1,11 +1,5 @@ ;; File explorer that lets you edit your filesystem. -(local user-cmds [[:Oil - (lambda [] - (let [oil (require :oil)] - (oil.open))) - {:nargs 0}]]) - (local opts {:keymaps {:g? :actions.show_help : :actions.select : :actions.select_vsplit @@ -21,12 +15,11 @@ :gs :actions.change_sort :gx :actions.open_external :g. :actions.toggle_hidden - "g\\\\" :actions.toggle_trash}}) - -(local keys [{1 "-" 2 :Oil :desc "Open parent directory"}]) + "g\\\\" :actions.toggle_trash} + :float {:padding 1 :max_width 64 :max_height 32}}) -(fn init [] - (let [cmds (require :util.cmds)] - (cmds.create-user-cmds user-cmds))) +(local keys [{1 "-" + 2 "lua require(\"oil\").open_float()" + :desc "Open parent directory"}]) -{1 :stevearc/oil.nvim : init : opts : keys} +{1 :stevearc/oil.nvim : opts : keys} -- cgit v1.2.3-70-g09d2