forgot
This commit is contained in:
@@ -3,7 +3,6 @@ require("options")
|
||||
require("config.lazy")
|
||||
require("mappings")
|
||||
require("autocmd")
|
||||
vim.cmd("source ~/.config/nvim/suda.vim")
|
||||
local time = tonumber( os.date "%H" )
|
||||
|
||||
vim.filetype.add({
|
||||
|
||||
+10
-10
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"CopilotChat.nvim": { "branch": "main", "commit": "07bcd20f408d9e43bdfab0e96c3f4d3aa860ef6a" },
|
||||
"CopilotChat.nvim": { "branch": "main", "commit": "3a562fd17e2fcd14d790a7c0c701b47d6724da60" },
|
||||
"LuaSnip": { "branch": "master", "commit": "c9b9a22904c97d0eb69ccb9bab76037838326817" },
|
||||
"auto-session": { "branch": "main", "commit": "9c3f977aafb56bd73ba0d082c4dcbdba5666faf3" },
|
||||
"base46-colors": { "branch": "main", "commit": "131ca742f6e8d1eb4c938a2519a94840ba129c2f" },
|
||||
@@ -12,27 +12,27 @@
|
||||
"command-completion.nvim": { "branch": "main", "commit": "56c98f8d59a88ed96a80d43abca74a60ba31ea3a" },
|
||||
"copilot.lua": { "branch": "master", "commit": "30321e33b03cb924fdcd6a806a0dc6fa0b0eafb9" },
|
||||
"fidget.nvim": { "branch": "main", "commit": "d9ba6b7bfe29b3119a610892af67602641da778e" },
|
||||
"focus.nvim": { "branch": "master", "commit": "d76338e58e49f844e8f6a7aff16a74a2a55a80ef" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "e5e9bf48211a13d9ee6c1077c88327c49c1ab4a0" },
|
||||
"harpoon": { "branch": "harpoon2", "commit": "ed1f853847ffd04b2b61c314865665e1dadf22c7" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||
"lightline-gruvbox.vim": { "branch": "master", "commit": "d233416d566e61f879bd19d9d498b01b1b7e336c" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "f4f791f67e70d378a754d02da068231d2352e5bc" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "1a31f824b9cd5bc6f342fc29e9a53b60d74af245" },
|
||||
"mason.nvim": { "branch": "main", "commit": "fc98833b6da5de5a9c5b1446ac541577059555be" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "68f0e5c3dab23261a945272032ee6700af86227a" },
|
||||
"nvim-cmp": { "branch": "main", "commit": "12509903a5723a876abd65953109f926f4634c30" },
|
||||
"nvim-dap": { "branch": "master", "commit": "52302f02fea3a490e55475de52fa4deb8af2eb11" },
|
||||
"nvim-cmp": { "branch": "main", "commit": "5a11682453ac6b13dbf32cd403da4ee9c07ef1c3" },
|
||||
"nvim-dap": { "branch": "master", "commit": "379cf26e9c457b66a0152cd5d018418c03720d47" },
|
||||
"nvim-jdtls": { "branch": "master", "commit": "2f7bff9b8d2ee1918b36ca55f19547d9d335a268" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "1110787f1b464888c59a044c48c5119d14078044" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "99c75820f2606b6b446cad7c75ec2ef7ee8a1317" },
|
||||
"nvim-notify": { "branch": "master", "commit": "22f29093eae7785773ee9d543f8750348b1a195c" },
|
||||
"nvim-tree.lua": { "branch": "master", "commit": "80523101f0ae48b7f1990e907b685a3d79776c01" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "d2ff4006418750aa8b91f280e66bdb623c891c95" },
|
||||
"nvim-tree.lua": { "branch": "master", "commit": "6709463b2d18e77f7a946027917aa00d4aaed6f4" },
|
||||
"nvim-treesitter": { "branch": "master", "commit": "93ce9feb4fabbb37b3e7f47d80f27be778f4d956" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "1020869742ecb191f260818234517f4a1515cfe8" },
|
||||
"onedarkpro.nvim": { "branch": "main", "commit": "b2712b3163f2b531cc26d1af07f49f683460e5a3" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "857c5ac632080dba10aae49dba902ce3abf91b35" },
|
||||
"presence.nvim": { "branch": "main", "commit": "87c857a56b7703f976d3a5ef15967d80508df6e6" },
|
||||
"rainbow-delimiters.nvim": { "branch": "master", "commit": "011d98eaa3a73b5a51d82ce5bc6b1397dde95562" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "a4e2c3e4fc54af78c7d351fe84399305119f59fa" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "78857db9e8d819d3cc1a9a7bdc1d39d127a36495" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "fa29c6c92631026a7ee41249c78bd91562e67a09" },
|
||||
"telescope.nvim": { "branch": "master", "commit": "814f102cd1da3dc78c7d2f20f2ef3ed3cdf0e6e4" },
|
||||
"undotree": { "branch": "main", "commit": "eab459ab87dd249617b5f7187bb69e614a083047" },
|
||||
"vim-fugitive": { "branch": "master", "commit": "4a745ea72fa93bb15dd077109afbb3d1809383f2" },
|
||||
"vim-suda": { "branch": "master", "commit": "9adda7d195222d4e2854efb2a88005a120296c47" }
|
||||
|
||||
@@ -1,62 +0,0 @@
|
||||
require("focus").setup({
|
||||
enable = true,
|
||||
commands = true,
|
||||
autoresize = {
|
||||
enable = true,
|
||||
width = 0,
|
||||
height = 0,
|
||||
minwidth = 0,
|
||||
minheight = 0,
|
||||
height_quickfix = 10,
|
||||
},
|
||||
split = {
|
||||
bufnew = false,
|
||||
tmux = false,
|
||||
},
|
||||
ui = {
|
||||
number = false,
|
||||
relativenumber = false,
|
||||
hybridnumber = false,
|
||||
absolutenumber_unfocussed = false,
|
||||
|
||||
cursorline = true,
|
||||
cursorcolumn = false,
|
||||
colorcolumn = {
|
||||
enable = false,
|
||||
list = '+1',
|
||||
},
|
||||
signcolumn = false,
|
||||
winhighlight = false,
|
||||
}
|
||||
})
|
||||
|
||||
local ignore_filetypes = {"NvimTree"}
|
||||
local ignore_buftypes = {"prompt", "popup"}
|
||||
|
||||
local augroup =
|
||||
vim.api.nvim_create_augroup("FocusDisable", { clear = true })
|
||||
|
||||
vim.api.nvim_create_autocmd("WinEnter", {
|
||||
group = augroup,
|
||||
callback = function(_)
|
||||
if vim.tbl_contains(ignore_buftypes, vim.bo.buftype)
|
||||
then
|
||||
vim.w.focus_disable = true
|
||||
else
|
||||
vim.w.focus_disable = false
|
||||
end
|
||||
end,
|
||||
desc = "Disable focus autoresize for BufType",
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd("FileType", {
|
||||
group = augroup,
|
||||
callback = function(_)
|
||||
if vim.tbl_contains(ignore_filetypes, vim.bo.filetype) then
|
||||
vim.b.focus_disable = true
|
||||
else
|
||||
vim.b.focus_disable = false
|
||||
end
|
||||
end,
|
||||
desc = "Disable focus autoresize for FileType",
|
||||
})
|
||||
@@ -0,0 +1,34 @@
|
||||
local harpoon = require("harpoon")
|
||||
|
||||
harpoon:setup()
|
||||
|
||||
local conf = require("telescope.config").values
|
||||
local function toggle_telescope(harpoon_files)
|
||||
local file_paths = {}
|
||||
for _, item in ipairs(harpoon_files.items) do
|
||||
table.insert(file_paths, item.value)
|
||||
end
|
||||
|
||||
require("telescope.pickers").new({}, {
|
||||
prompt_title = "Harpoon",
|
||||
finder = require("telescope.finders").new_table({
|
||||
results = file_paths,
|
||||
}),
|
||||
previewer = conf.file_previewer({}),
|
||||
sorter = conf.generic_sorter({}),
|
||||
}):find()
|
||||
end
|
||||
|
||||
vim.keymap.set("n", "<C-e>", function() toggle_telescope(harpoon:list()) end,
|
||||
{ desc = "Open harpoon window" })
|
||||
|
||||
vim.keymap.set("n", "<leader>a", function() harpoon:list():add() end)
|
||||
vim.keymap.set("n", "<C-e>", function() harpoon.ui:toggle_quick_menu(harpoon:list()) end)
|
||||
|
||||
vim.keymap.set("n", "<C-h>", function() harpoon:list():select(1) end)
|
||||
vim.keymap.set("n", "<C-t>", function() harpoon:list():select(2) end)
|
||||
vim.keymap.set("n", "<C-n>", function() harpoon:list():select(3) end)
|
||||
vim.keymap.set("n", "<C-s>", function() harpoon:list():select(4) end)
|
||||
|
||||
vim.keymap.set("n", "<C-S-P>", function() harpoon:list():prev() end)
|
||||
vim.keymap.set("n", "<C-S-N>", function() harpoon:list():next() end)
|
||||
+2
-2
@@ -20,8 +20,8 @@ map("n", "<A-c>", vim.cmd.CopilotChatToggle)
|
||||
map("i", "<A-c>", vim.cmd.CopilotChatToggle)
|
||||
map("v", "<A-c>", vim.cmd.CopilotChatToggle)
|
||||
|
||||
map('n', '<leader>e', vim.cmd.NvimTreeToggle)
|
||||
-- map('n', '<leader>e', function() Snacks.explorer() end)
|
||||
-- map('n', '<leader>e', vim.cmd.NvimTreeToggle)
|
||||
map('n', '<leader>e', function() Snacks.explorer() end)
|
||||
map('n', '<leader>u', require('undotree').toggle, { noremap = true, silent = true })
|
||||
|
||||
map("n", "<A-->", ":bdelete<CR>")
|
||||
|
||||
+14
-6
@@ -29,6 +29,10 @@ return {
|
||||
},
|
||||
{
|
||||
"lambdalisue/vim-suda",
|
||||
init = function()
|
||||
vim.g.suda_smart_edit = 1
|
||||
-- vim.g["suda#noninteractive"] = 1
|
||||
end,
|
||||
},
|
||||
{
|
||||
"nvim-tree/nvim-web-devicons",
|
||||
@@ -182,13 +186,17 @@ return {
|
||||
{
|
||||
"andweeb/presence.nvim",
|
||||
},
|
||||
{
|
||||
"nvim-focus/focus.nvim",
|
||||
config = function()
|
||||
require("config.focus")
|
||||
end,
|
||||
},
|
||||
{
|
||||
"mfussenegger/nvim-jdtls",
|
||||
},
|
||||
{
|
||||
"ThePrimeagen/harpoon",
|
||||
branch = "harpoon2",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
config = function()
|
||||
require("config.harpoon")
|
||||
end,
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user