Move to nixos-23.11
This commit is contained in:
parent
659fb33ca7
commit
38a7932c2c
25 changed files with 1001 additions and 543 deletions
home/features/neovim/config/lua/my
|
@ -89,7 +89,7 @@ function M.setup()
|
|||
-- In the future, I might get this on my keyboard firmware.
|
||||
vim.keymap.set({ "i", "v" }, "<f10>", "<Esc>", { desc = "Exit insert mode" }) -- Exit inset mode using *jk*
|
||||
vim.keymap.set({ "n", "v" }, "<f11>", '"+', { desc = "Use global clipboard" }) -- Use global clipboard with *cp*
|
||||
M.nmap("<f12>", ":silent write<cr>", "Save current file") -- Save using *ji*
|
||||
M.nmap("<f12>", "<cmd>silent write<cr>", "Save current file", true) -- Save using *ji*
|
||||
-- }}}
|
||||
-- {{{ Shift-Enter for not continuing the current comment
|
||||
-- This does not preserve intendation. Not sure what a better solution would look like.
|
||||
|
|
|
@ -95,14 +95,6 @@ return {
|
|||
end,
|
||||
},
|
||||
|
||||
-- Helper libs
|
||||
{
|
||||
"nvim-lua/plenary.nvim",
|
||||
-- Autoload when running tests
|
||||
cmd = { "PlenaryBustedDirectory", "PlenaryBustedFile" },
|
||||
},
|
||||
"MunifTanjim/nui.nvim",
|
||||
"nvim-tree/nvim-web-devicons", -- nice looking icons
|
||||
{
|
||||
"mateiadrielrafael/scrap.nvim",
|
||||
event = "InsertEnter",
|
||||
|
@ -111,14 +103,6 @@ return {
|
|||
end,
|
||||
}, -- vim-abolish rewrite
|
||||
|
||||
{
|
||||
"terrortylor/nvim-comment",
|
||||
keys = { "gc", "gcc", { "gc", mode = "v" } },
|
||||
config = function()
|
||||
require("nvim_comment").setup()
|
||||
end,
|
||||
},
|
||||
|
||||
{
|
||||
-- easly switch between tmux and vim panes
|
||||
"christoomey/vim-tmux-navigator",
|
||||
|
@ -128,13 +112,6 @@ return {
|
|||
and env.firenvim.not_active(),
|
||||
},
|
||||
|
||||
{
|
||||
-- track time usage
|
||||
"wakatime/vim-wakatime",
|
||||
event = "VeryLazy",
|
||||
cond = env.vscode.not_active() and env.firenvim.not_active(),
|
||||
},
|
||||
|
||||
{
|
||||
-- show progress for lsp stuff
|
||||
"j-hui/fidget.nvim",
|
||||
|
@ -144,15 +121,6 @@ return {
|
|||
config = true,
|
||||
},
|
||||
|
||||
{
|
||||
-- export to pastebin like services
|
||||
"rktjmp/paperplanes.nvim",
|
||||
opts = {
|
||||
provider = "paste.rs",
|
||||
},
|
||||
cmd = "PP",
|
||||
},
|
||||
|
||||
{
|
||||
-- case switching + the subvert command
|
||||
"tpope/vim-abolish",
|
||||
|
@ -187,16 +155,6 @@ return {
|
|||
keys = "<leader>yg",
|
||||
},
|
||||
|
||||
{
|
||||
-- discord rich presence
|
||||
"andweeb/presence.nvim",
|
||||
cond = env.vscode.not_active() and env.firenvim.not_active(),
|
||||
config = function()
|
||||
require("presence"):setup()
|
||||
end,
|
||||
event = "VeryLazy",
|
||||
},
|
||||
|
||||
-- Live command preview for stuff like :norm
|
||||
{
|
||||
"smjonas/live-command.nvim",
|
||||
|
@ -210,16 +168,4 @@ return {
|
|||
event = "VeryLazy",
|
||||
-- cond = false,
|
||||
},
|
||||
{
|
||||
"mbbill/undotree",
|
||||
cmd = "UndotreeToggle",
|
||||
init = function()
|
||||
vim.keymap.set(
|
||||
"n",
|
||||
"<leader>u",
|
||||
"<cmd>UndotreeToggle<cr>",
|
||||
{ desc = "[U]ndo tree" }
|
||||
)
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
|
|
@ -2,6 +2,7 @@ local env = require("my.helpers.env")
|
|||
|
||||
local M = {
|
||||
"L3MON4D3/LuaSnip", -- snippeting engine
|
||||
version = "v2",
|
||||
cond = env.vscode.not_active(),
|
||||
}
|
||||
|
||||
|
|
|
@ -3,8 +3,7 @@ local env = require("my.helpers.env")
|
|||
|
||||
local M = {
|
||||
"echasnovski/mini.files",
|
||||
version = "main",
|
||||
event = "VeryLazy",
|
||||
keys = { "<C-S-F>" },
|
||||
cond = env.vscode.not_active() and env.firenvim.not_active(),
|
||||
}
|
||||
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
local M = {
|
||||
"echasnovski/mini.operators",
|
||||
version = false,
|
||||
event = "VeryLazy",
|
||||
opts = {},
|
||||
}
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
local M = {
|
||||
"echasnovski/mini.surround",
|
||||
version = "main",
|
||||
event = "VeryLazy",
|
||||
}
|
||||
|
||||
|
|
|
@ -68,8 +68,7 @@ end
|
|||
-- {{{ Main config runtime
|
||||
local function recursive_assign(source, destination)
|
||||
for key, value in pairs(source) do
|
||||
if type(value) == "table" then
|
||||
destination[key] = destination[key] or {}
|
||||
if type(value) == "table" and type(destination[key]) == "table" then
|
||||
recursive_assign(value, destination[key])
|
||||
else
|
||||
destination[key] = value
|
||||
|
@ -79,7 +78,7 @@ end
|
|||
|
||||
function M.configure(opts, context)
|
||||
if type(opts.vim) == "table" then
|
||||
recursive_assign(opts, vim)
|
||||
recursive_assign(opts.vim, vim)
|
||||
end
|
||||
|
||||
if type(opts.keys) == "table" then
|
||||
|
@ -117,10 +116,14 @@ function M.configure(opts, context)
|
|||
if
|
||||
type(context) == "table"
|
||||
and context.opts ~= nil
|
||||
and vim.inspect(context.opts) ~= "{}"
|
||||
and context.lazy ~= nil
|
||||
then
|
||||
-- This is a terrible way to do it :/
|
||||
require(context.lazy.name).setup(context.opts)
|
||||
local status, module = pcall(require, context.lazy.name)
|
||||
if status then
|
||||
module.setup(context.opts)
|
||||
end
|
||||
end
|
||||
|
||||
if type(opts.callback) == "function" then
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue