diff --git a/modules/common/shell/default.nix b/modules/common/shell/default.nix index d5e4634..d3c37f7 100644 --- a/modules/common/shell/default.nix +++ b/modules/common/shell/default.nix @@ -75,7 +75,7 @@ in export PATH="/run/current-system/sw/bin:/nix/var/nix/profiles/default/bin:/etc/profiles/per-user/$USER/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin''${PATH:+:}''${PATH}" source ${config'.home.sessionVariablesPackage}/etc/profile.d/hm-session-vars.sh - if [ -z "$INTELLIJ_ENVIRONMENT_READER" ]; then + if [ -z "$INTELLIJ_ENVIRONMENT_READER" ] && [ -z "$skip" ]; then SHELL='${lib.getExe <| lib.head config'.shellsByPriority}' exec "$SHELL" fi ''; diff --git a/modules/dotfiles/nvim/lua/thegeneralist/lazy/snacks.lua b/modules/dotfiles/nvim/lua/thegeneralist/lazy/snacks.lua index 2310ca9..5218c58 100644 --- a/modules/dotfiles/nvim/lua/thegeneralist/lazy/snacks.lua +++ b/modules/dotfiles/nvim/lua/thegeneralist/lazy/snacks.lua @@ -38,6 +38,12 @@ return { enabled = true, preset = { keys = { + { + icon = " ", + key = "t", + desc = "TODOs", + action = ":lua Snacks.picker.todo_comments()", + }, { icon = " ", key = "f", @@ -81,7 +87,7 @@ return { cmd = "greeting", hl = "header", ttl = 60, - height = 3, + height = 5, padding = 2, align = "center", }, diff --git a/modules/dotfiles/nvim/lua/thegeneralist/lazy/whichkey.lua b/modules/dotfiles/nvim/lua/thegeneralist/lazy/whichkey.lua index 07eea0e..8ba00ab 100644 --- a/modules/dotfiles/nvim/lua/thegeneralist/lazy/whichkey.lua +++ b/modules/dotfiles/nvim/lua/thegeneralist/lazy/whichkey.lua @@ -1,72 +1,77 @@ return { - "folke/which-key.nvim", - event = "VeryLazy", - commit = "af4ded85542d40e190014c732fa051bdbf88be3d", - init = function() - vim.o.timeout = true - vim.o.timeoutlen = 300 - end, - opts = { - t = { - name = '+Trouble', - w = { 'TroubleToggle workspace_diagnostics', 'Workspace Diagnostics' }, - d = { 'TroubleToggle document_diagnostics', 'Document Diagnostics' }, - q = { 'TroubleToggle quickfix', 'Quickfix' }, - l = { 'TroubleToggle loclist', 'Location List' }, - }, - g = { - R = { 'TroubleToggle lsp_references', 'LSP References' }, - h = { - name = "+Git", - h = { - name = "+Github", - c = { - name = "+Commits", - c = { "GHCloseCommit", "Close" }, - e = { "GHExpandCommit", "Expand" }, - o = { "GHOpenToCommit", "Open To" }, - p = { "GHPopOutCommit", "Pop Out" }, - z = { "GHCollapseCommit", "Collapse" }, - }, - i = { - name = "+Issues", - p = { "GHPreviewIssue", "Preview" }, - }, - l = { - name = "+Litee", - t = { "LTPanel", "Toggle Panel" }, - }, - r = { - name = "+Review", - b = { "GHStartReview", "Begin" }, - c = { "GHCloseReview", "Close" }, - d = { "GHDeleteReview", "Delete" }, - e = { "GHExpandReview", "Expand" }, - s = { "GHSubmitReview", "Submit" }, - z = { "GHCollapseReview", "Collapse" }, - }, - p = { - name = "+Pull Request", - c = { "GHClosePR", "Close" }, - d = { "GHPRDetails", "Details" }, - e = { "GHExpandPR", "Expand" }, - o = { "GHOpenPR", "Open" }, - p = { "GHPopOutPR", "PopOut" }, - r = { "GHRefreshPR", "Refresh" }, - t = { "GHOpenToPR", "Open To" }, - z = { "GHCollapsePR", "Collapse" }, - }, - t = { - name = "+Threads", - c = { "GHCreateThread", "Create" }, - n = { "GHNextThread", "Next" }, - t = { "GHToggleThread", "Toggle" }, - }, - }, - }, - }, - --conf end - } + "folke/which-key.nvim", + event = "VeryLazy", + commit = "af4ded85542d40e190014c732fa051bdbf88be3d", + init = function() + vim.o.timeout = true + vim.o.timeoutlen = 300 + end, + opts = { + t = { + name = "+Trouble", + w = { "TroubleToggle workspace_diagnostics", "Workspace Diagnostics" }, + d = { "TroubleToggle document_diagnostics", "Document Diagnostics" }, + q = { "TroubleToggle quickfix", "Quickfix" }, + l = { "TroubleToggle loclist", "Location List" }, + }, + g = { + R = { "TroubleToggle lsp_references", "LSP References" }, + h = { + name = "+Git", + h = { + name = "+Github", + c = { + name = "+Commits", + c = { "GHCloseCommit", "Close" }, + e = { "GHExpandCommit", "Expand" }, + o = { "GHOpenToCommit", "Open To" }, + p = { "GHPopOutCommit", "Pop Out" }, + z = { "GHCollapseCommit", "Collapse" }, + }, + i = { + name = "+Issues", + p = { "GHPreviewIssue", "Preview" }, + }, + l = { + name = "+Litee", + t = { "LTPanel", "Toggle Panel" }, + }, + r = { + name = "+Review", + b = { "GHStartReview", "Begin" }, + c = { "GHCloseReview", "Close" }, + d = { "GHDeleteReview", "Delete" }, + e = { "GHExpandReview", "Expand" }, + s = { "GHSubmitReview", "Submit" }, + z = { "GHCollapseReview", "Collapse" }, + }, + p = { + name = "+Pull Request", + c = { "GHClosePR", "Close" }, + d = { "GHPRDetails", "Details" }, + e = { "GHExpandPR", "Expand" }, + o = { "GHOpenPR", "Open" }, + p = { "GHPopOutPR", "PopOut" }, + r = { "GHRefreshPR", "Refresh" }, + t = { "GHOpenToPR", "Open To" }, + z = { "GHCollapsePR", "Collapse" }, + }, + t = { + name = "+Threads", + c = { "GHCreateThread", "Create" }, + n = { "GHNextThread", "Next" }, + t = { "GHToggleThread", "Toggle" }, + }, + }, + }, + }, + f = { + name = "File Operations", + r = { ":lua vim.lsp.buf.format()", "Fo[R]mat" }, + t = { ":lua Snacks.picker.todo_comments()", "TODOs" }, + }, + --conf end + }, } --local wk = require("which-key") --wk.register({ diff --git a/modules/dotfiles/nvim/lua/thegeneralist/remap.lua b/modules/dotfiles/nvim/lua/thegeneralist/remap.lua index c626618..e539077 100755 --- a/modules/dotfiles/nvim/lua/thegeneralist/remap.lua +++ b/modules/dotfiles/nvim/lua/thegeneralist/remap.lua @@ -16,10 +16,10 @@ vim.keymap.set("n", "n", "nzzzv") vim.keymap.set("n", "N", "Nzzzv") vim.keymap.set("n", "vwm", function() - require("vim-with-me").StartVimWithMe() + require("vim-with-me").StartVimWithMe() end) vim.keymap.set("n", "svwm", function() - require("vim-with-me").StopVimWithMe() + require("vim-with-me").StopVimWithMe() end) vim.keymap.set("n", "vs", "v") @@ -38,7 +38,6 @@ vim.keymap.set("i", "", "") vim.keymap.set("n", "Q", "") vim.keymap.set("n", "", "silent !tmux neww tmux-sessionizer") -vim.keymap.set("n", "fr", vim.lsp.buf.format) vim.keymap.set("n", "m", "cnextzz") vim.keymap.set("n", "m", "cprevzz") @@ -54,19 +53,19 @@ vim.keymap.set("n", "vpp", "e ~/.dotfiles/nvim/.config/nvim/lua/the vim.keymap.set("n", "mr", "CellularAutomaton make_it_rain") vim.keymap.set("n", "", function() - vim.cmd("so") + vim.cmd("so") end) vim.keymap.set("n", "zh", "$viBhzf", { - desc = "Fold { block", + desc = "Fold { block", }) vim.keymap.set("n", "zj", "$vi[hzf", { - desc = "Fold [ block", + desc = "Fold [ block", }) vim.keymap.set("n", "zk", "$vibhzf", { - desc = "Fold ( block", + desc = "Fold ( block", }) vim.keymap.set("n", "ga", "EasyAlign") @@ -85,9 +84,9 @@ vim.keymap.set("v", "", "e", "jq") vim.keymap.set("n", "w", function() - vim.ui.input({ prompt = "Enter value for shiftwidth: " }, function(input) - vim.o.shiftwidth = tonumber(input) - end) + vim.ui.input({ prompt = "Enter value for shiftwidth: " }, function(input) + vim.o.shiftwidth = tonumber(input) + end) end) -- vim.keymap.set("n", "tc", function() -- -- local file_number = tonumber(vim.fn.input("File number > "), 10)