From 285708a68aa4ba14456107673f65731b2a2bcd2f Mon Sep 17 00:00:00 2001 From: Nicolas Goudry Date: Sun, 9 Jun 2024 09:19:43 +0200 Subject: [PATCH] style(plugins/neo-tree): format --- plugins/neo-tree.nix | 63 ++++++++++++++++++++++---------------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/plugins/neo-tree.nix b/plugins/neo-tree.nix index e332ee4..91abadc 100644 --- a/plugins/neo-tree.nix +++ b/plugins/neo-tree.nix @@ -215,41 +215,42 @@ end end ''; - in[ - # https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/neo-tree.lua#L21-L37 - { - desc = "Open explorer on startup with directory"; - event = "BufEnter"; - group = "neotree"; + in + [ + # https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/neo-tree.lua#L21-L37 + { + desc = "Open explorer on startup with directory"; + event = "BufEnter"; + group = "neotree"; - callback.__raw = '' - function() - if package.loaded["neo-tree"] then - return true - else - local stats = vim.loop.fs_stat(vim.api.nvim_buf_get_name(0)) - if stats and stats.type == "directory" then + callback.__raw = '' + function() + if package.loaded["neo-tree"] then return true + else + local stats = vim.loop.fs_stat(vim.api.nvim_buf_get_name(0)) + if stats and stats.type == "directory" then + return true + end end end - end - ''; - } - # https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/neo-tree.lua#L25-L35 - { - desc = "Refresh explorer sources when closing lazygit"; - event = "TermClose"; - group = "neotree"; - pattern = "*lazygit*"; - callback.__raw = refresh; - } - { - desc = "Refresh explorer sources on focus"; - event = "FocusGained"; - group = "neotree"; - callback.__raw = refresh; - } - ]; + ''; + } + # https://github.com/AstroNvim/AstroNvim/blob/v4.7.7/lua/astronvim/plugins/neo-tree.lua#L25-L35 + { + desc = "Refresh explorer sources when closing lazygit"; + event = "TermClose"; + group = "neotree"; + pattern = "*lazygit*"; + callback.__raw = refresh; + } + { + desc = "Refresh explorer sources on focus"; + event = "FocusGained"; + group = "neotree"; + callback.__raw = refresh; + } + ]; keymaps = [ {