From 971e0d6417cbe708f182673dc905bd471f34c0e0 Mon Sep 17 00:00:00 2001 From: ttak0422 Date: Sat, 25 Jan 2025 20:03:42 +0900 Subject: [PATCH] chore: use lir --- fnl/prelude.fnl | 3 ++- lua/autogen/prelude.lua | 2 +- main/default.nix | 2 +- 3 files changed, 4 insertions(+), 3 deletions(-) diff --git a/fnl/prelude.fnl b/fnl/prelude.fnl index 561e881..411097a 100644 --- a/fnl/prelude.fnl +++ b/fnl/prelude.fnl @@ -111,7 +111,8 @@ [:gb (cmd :ToggleGitBlame) (desc " blame")] ;; filter [:tb - (lcmd "require('oil').toggle_float()") + ; (lcmd "require('oil').toggle_float()") + (lcmd "require('lir.float').toggle()") (desc " explorer")] [:tB (lcmd "require('oil').open()") diff --git a/lua/autogen/prelude.lua b/lua/autogen/prelude.lua index 5294915..e18a806 100644 --- a/lua/autogen/prelude.lua +++ b/lua/autogen/prelude.lua @@ -49,7 +49,7 @@ do return _5_ end mk_toggle = _4_() - for _, K in ipairs({{"ff", cmd("Telescope live_grep_args"), desc("search by content")}, {"fF", cmd("Telescope ast_grep"), desc("search by AST")}, {"fb", cmd("TelescopeB"), desc("search by buffer")}, {"ft", cmd("Telescope sonictemplate templates"), desc("search templates")}, {"fh", cmd("Legendary"), desc("Search command palette")}, {"H", lcmd("require('harpoon').ui:toggle_quick_menu(require('harpoon'):list(),{border='none'})"), desc("Show registered file")}, {"ha", lcmd("require('harpoon'):list():add()"), desc("Register file")}, {"fp", cmd("Ddu -name=fd file_fd"), desc("search by file name")}, {"fP", cmd("Ddu -name=ghq ghq"), desc("search repo (ghq)")}, {"fru", cmd("Ddu -name=mru mru"), desc("MRU (Most Recently Used files)")}, {"frw", cmd("Ddu -name=mrw mrw"), desc("MRW (Most Recently Written files)")}, {"frr", cmd("Ddu -name=mrr mrr"), desc("MRR (Most Recent git Repositories)")}, {"frd", cmd("Ddu -name=mrd mrd"), desc("MRD (Most Recent Directories)")}, {"mq", cmd("MarksQFListBuf"), desc("marks in current buffer")}, {"mQ", cmd("MarksQFListGlobal"), desc("marks in all buffer")}, {"U", cmd("UndotreeToggle", desc("toggle undotree"))}, {"nt", cmd("Neorg journal today"), desc("\238\152\179 Today")}, {"ny", cmd("Neorg journal yesterday"), desc("\238\152\179 Yesterday")}, {"N", cmd("Neorg"), desc("\238\152\179 Enter")}, {"nn", cmd("NeorgUID"), desc("\238\152\179 UID")}, {"ngg", cmd("NeorgGit"), desc("\238\152\179 Git")}, {"ngb", cmd("NeorgGitBranch"), desc("\238\152\179 Git (branch)")}, {"fn", cmd("NeorgFuzzySearch"), desc("find Neorg linkable")}, {"G", cmd("Neogit"), desc("\239\135\147 client")}, {"gb", cmd("ToggleGitBlame"), desc("\239\135\147 blame")}, {"tb", lcmd("require('oil').toggle_float()"), desc("\239\136\133 explorer")}, {"tB", lcmd("require('oil').open()"), desc("\239\136\133 explorer")}, {"q", cmd("BufDel"), desc("close buffer")}, {"Q", cmd("BufDelAll"), desc("close all buffers")}, {"A", cmd("tabclose")}, {"ts", cmd("Screenkey toggle"), desc("toggle screenkey")}, {"tc", cmd("ColorizerToggle"), desc("toggle colorizer")}, {"tt", cmd("NoNeckPain"), desc("toggle no neck pain")}, {"tm", lcmd("require('codewindow').toggle_minimap()"), desc("toggle minimap")}, {"to", cmd("AerialToggle"), desc("toggle outline")}, {"tj", cmd("lua require('treesj').toggle({ split = { recursive = false }})"), desc("toggle split/join")}, {"tJ", cmd("lua require('treesj').toggle({ split = { recursive = true }})"), desc("toggle recursive split/join")}, {"tq", mk_toggle(1, "qf", nil), desc("toggle quickfix")}, {"td", mk_toggle(2, "trouble", {mode = "diagnostics", filter = {buf = 0}}), desc("toggle diagnostics (document)")}, {"tD", mk_toggle(3, "trouble", {mode = "diagnostics"}), desc("toggle diagnostics (workspace)")}}) do + for _, K in ipairs({{"ff", cmd("Telescope live_grep_args"), desc("search by content")}, {"fF", cmd("Telescope ast_grep"), desc("search by AST")}, {"fb", cmd("TelescopeB"), desc("search by buffer")}, {"ft", cmd("Telescope sonictemplate templates"), desc("search templates")}, {"fh", cmd("Legendary"), desc("Search command palette")}, {"H", lcmd("require('harpoon').ui:toggle_quick_menu(require('harpoon'):list(),{border='none'})"), desc("Show registered file")}, {"ha", lcmd("require('harpoon'):list():add()"), desc("Register file")}, {"fp", cmd("Ddu -name=fd file_fd"), desc("search by file name")}, {"fP", cmd("Ddu -name=ghq ghq"), desc("search repo (ghq)")}, {"fru", cmd("Ddu -name=mru mru"), desc("MRU (Most Recently Used files)")}, {"frw", cmd("Ddu -name=mrw mrw"), desc("MRW (Most Recently Written files)")}, {"frr", cmd("Ddu -name=mrr mrr"), desc("MRR (Most Recent git Repositories)")}, {"frd", cmd("Ddu -name=mrd mrd"), desc("MRD (Most Recent Directories)")}, {"mq", cmd("MarksQFListBuf"), desc("marks in current buffer")}, {"mQ", cmd("MarksQFListGlobal"), desc("marks in all buffer")}, {"U", cmd("UndotreeToggle", desc("toggle undotree"))}, {"nt", cmd("Neorg journal today"), desc("\238\152\179 Today")}, {"ny", cmd("Neorg journal yesterday"), desc("\238\152\179 Yesterday")}, {"N", cmd("Neorg"), desc("\238\152\179 Enter")}, {"nn", cmd("NeorgUID"), desc("\238\152\179 UID")}, {"ngg", cmd("NeorgGit"), desc("\238\152\179 Git")}, {"ngb", cmd("NeorgGitBranch"), desc("\238\152\179 Git (branch)")}, {"fn", cmd("NeorgFuzzySearch"), desc("find Neorg linkable")}, {"G", cmd("Neogit"), desc("\239\135\147 client")}, {"gb", cmd("ToggleGitBlame"), desc("\239\135\147 blame")}, {"tb", lcmd("require('lir.float').toggle()"), desc("\239\136\133 explorer")}, {"tB", lcmd("require('oil').open()"), desc("\239\136\133 explorer")}, {"q", cmd("BufDel"), desc("close buffer")}, {"Q", cmd("BufDelAll"), desc("close all buffers")}, {"A", cmd("tabclose")}, {"ts", cmd("Screenkey toggle"), desc("toggle screenkey")}, {"tc", cmd("ColorizerToggle"), desc("toggle colorizer")}, {"tt", cmd("NoNeckPain"), desc("toggle no neck pain")}, {"tm", lcmd("require('codewindow').toggle_minimap()"), desc("toggle minimap")}, {"to", cmd("AerialToggle"), desc("toggle outline")}, {"tj", cmd("lua require('treesj').toggle({ split = { recursive = false }})"), desc("toggle split/join")}, {"tJ", cmd("lua require('treesj').toggle({ split = { recursive = true }})"), desc("toggle recursive split/join")}, {"tq", mk_toggle(1, "qf", nil), desc("toggle quickfix")}, {"td", mk_toggle(2, "trouble", {mode = "diagnostics", filter = {buf = 0}}), desc("toggle diagnostics (document)")}, {"tD", mk_toggle(3, "trouble", {mode = "diagnostics"}), desc("toggle diagnostics (workspace)")}}) do vim.keymap.set("n", ("" .. K[1]), K[2], (K[3] or opts)) end for m, ks in pairs({n = {{"\194\165", "\\"}, {"", cmd("OpenMenu")}}, i = {{"\194\165", "\\"}}, c = {{"\194\165", "\\"}}, t = {{"\194\165", "\\"}}, v = {{"R", cmd("FlowRunSelected")}, {"", cmd("OpenMenu")}}}) do diff --git a/main/default.nix b/main/default.nix index 81dd83a..49e277b 100644 --- a/main/default.nix +++ b/main/default.nix @@ -165,7 +165,7 @@ let copilot-chat dotfyle-metadata hardtime - # lir + lir logrotate menu minty