mirror of
https://github.com/dcarrillo/dotfiles.git
synced 2025-07-01 19:49:25 +00:00
[neovim] Minimal refactor
This commit is contained in:
@ -16,7 +16,7 @@ local kind_icons = {
|
||||
Color = " ",
|
||||
Constant = " ",
|
||||
Constructor = " ",
|
||||
Copilot = " ",
|
||||
Copilot = " ",
|
||||
Enum = " ",
|
||||
EnumMember = " ",
|
||||
Event = " ",
|
||||
|
@ -15,3 +15,22 @@ require("copilot").setup({
|
||||
})
|
||||
|
||||
require("copilot_cmp").setup()
|
||||
|
||||
local prompts = {
|
||||
-- Code related prompts
|
||||
Explain = "Please explain how the following code works.",
|
||||
Review = "Please review the following code and provide suggestions for improvement.",
|
||||
Tests = "Please explain how the selected code works, then generate unit tests for it.",
|
||||
Refactor = "Please refactor the following code to improve its clarity and readability.",
|
||||
FixCode = "Please fix the following code to make it work as intended.",
|
||||
BetterNamings = "Please provide better names for the following variables and functions.",
|
||||
-- Text related prompts
|
||||
Spelling = "Please correct any grammar and spelling errors in the following text. Respect the markdown format when provided",
|
||||
Wording = "Please improve the grammar and wording of the following text. Respect the markdown format when provided",
|
||||
}
|
||||
require("CopilotChat").setup({
|
||||
show_help = "yes",
|
||||
debug = false,
|
||||
disable_extra_info = "yes",
|
||||
prompts = prompts,
|
||||
})
|
||||
|
@ -11,6 +11,7 @@ require("plugins.illuminate")
|
||||
require("plugins.indentline")
|
||||
require("plugins.lsp")
|
||||
require("plugins.go")
|
||||
require("plugins.typescript")
|
||||
require("plugins.neotest")
|
||||
require("plugins.dap")
|
||||
require("plugins.noice")
|
||||
|
@ -8,6 +8,7 @@ require("lspsaga").setup({
|
||||
},
|
||||
code_action = {
|
||||
show_server_name = true,
|
||||
extend_gitsigns = true,
|
||||
},
|
||||
rename = {
|
||||
auto_save = true,
|
||||
|
@ -54,7 +54,7 @@ local get_filetype = function()
|
||||
|
||||
if ft == "yaml" then
|
||||
local schema = require("yaml-companion").get_buf_schema(0)
|
||||
if schema.result[1].name == "none" then
|
||||
if not schema or not schema.result or not schema.result[1].name then
|
||||
return ft
|
||||
end
|
||||
|
||||
@ -98,7 +98,20 @@ require("lualine").setup({
|
||||
return true
|
||||
end,
|
||||
},
|
||||
"copilot",
|
||||
{
|
||||
"copilot",
|
||||
symbols = {
|
||||
status = {
|
||||
icons = {
|
||||
enabled = " ",
|
||||
sleep = " ",
|
||||
disabled = " ",
|
||||
warning = " ",
|
||||
unknown = " ",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
lsp_progress,
|
||||
{
|
||||
require("noice").api.status.search.get,
|
||||
|
5
.config/nvim/lua/plugins/typescript.lua
Normal file
5
.config/nvim/lua/plugins/typescript.lua
Normal file
@ -0,0 +1,5 @@
|
||||
require("typescript-tools").setup({
|
||||
settings = {
|
||||
complete_function_calls = true,
|
||||
},
|
||||
})
|
Reference in New Issue
Block a user