1
0
mirror of https://github.com/dcarrillo/dotfiles.git synced 2024-12-22 12:48:01 +00:00

[neovim] Add rose-pine theme and some refactors

This commit is contained in:
Daniel Carrillo 2024-03-17 18:25:34 +01:00
parent aceaa089f0
commit e7bf2eb91d
Signed by: dcarrillo
GPG Key ID: E4CD5C09DAED6E16
11 changed files with 112 additions and 44 deletions

View File

@ -1,7 +1,8 @@
# (Github Dark Dimmed) Colors for kitty # (Github Dark Dimmed) Colors for kitty
# https://github.com/projekt0n/github-theme-contrib/blob/main/themes/kitty/github_dark_dimmed.conf # https://github.com/projekt0n/github-theme-contrib/blob/main/themes/kitty/github_dark_dimmed.conf
background #22272e # Customized
background #232136
foreground #adbac7 foreground #adbac7
url_color #adbac7 url_color #adbac7
@ -10,7 +11,8 @@ cursor_text_color background
# Tabs # Tabs
active_tab_background #57ab5a active_tab_background #57ab5a
active_tab_foreground #22272e # Customized
active_tab_foreground #232136
inactive_tab_background #253040 inactive_tab_background #253040
inactive_tab_foreground #636e7b inactive_tab_foreground #636e7b

View File

@ -0,0 +1,55 @@
## name: Rosé Pine Moon
## author: mvllow
## license: MIT
## upstream: https://github.com/rose-pine/kitty/blob/main/dist/rose-pine-moon.conf
## blurb: All natural pine, faux fur and a bit of soho vibes for the classy minimalist
foreground #e0def4
background #232136
selection_foreground #e0def4
selection_background #44415a
cursor #56526e
cursor_text_color #e0def4
url_color #c4a7e7
active_tab_foreground #e0def4
active_tab_background #393552
inactive_tab_foreground #6e6a86
inactive_tab_background #232136
active_border_color #3e8fb0
inactive_border_color #44415a
# black
color0 #393552
color8 #6e6a86
# red
color1 #eb6f92
color9 #eb6f92
# green
color2 #3e8fb0
color10 #3e8fb0
# yellow
color3 #f6c177
color11 #f6c177
# blue
color4 #9ccfd8
color12 #9ccfd8
# magenta
color5 #c4a7e7
color13 #c4a7e7
# cyan
color6 #ea9a97
color14 #ea9a97
# white
color7 #e0def4
color15 #e0def4

View File

@ -46,6 +46,7 @@ hide_window_decorations yes
#include color_schemes/tokyo_night_moon.conf #include color_schemes/tokyo_night_moon.conf
include color_schemes/github_dimmed.conf include color_schemes/github_dimmed.conf
#include color_schemes/rose-pine-moon.conf
#: }}} #: }}}

View File

@ -16,3 +16,4 @@ Neovim conf heavily adapted to suit my needs, formerly based on LunarVim's [basi
* hadolint * hadolint
* revive * revive
* tree-sitter-cli * tree-sitter-cli
* Optional for copilotchat: `sudo luarocks install --lua-version 5.1 tiktoken_core`

View File

@ -12,60 +12,63 @@
"copilot-cmp": { "branch": "master", "commit": "72fbaa03695779f8349be3ac54fa8bd77eed3ee3" }, "copilot-cmp": { "branch": "master", "commit": "72fbaa03695779f8349be3ac54fa8bd77eed3ee3" },
"copilot-lualine": { "branch": "main", "commit": "9e226cf8f4653e13ec282f5878d66aa435899c8c" }, "copilot-lualine": { "branch": "main", "commit": "9e226cf8f4653e13ec282f5878d66aa435899c8c" },
"copilot.lua": { "branch": "master", "commit": "f7612f5af4a7d7615babf43ab1e67a2d790c13a6" }, "copilot.lua": { "branch": "master", "commit": "f7612f5af4a7d7615babf43ab1e67a2d790c13a6" },
"copilotchat.nvim": { "branch": "main", "commit": "b99aabf5138f3949f139df334828d0eb7859cc27" }, "copilotchat.nvim": { "branch": "canary", "commit": "36313d9831b96e91b6e3b38e00a770803ea50201" },
"diffview.nvim": { "branch": "main", "commit": "3dc498c9777fe79156f3d32dddd483b8b3dbd95f" }, "diffview.nvim": { "branch": "main", "commit": "3dc498c9777fe79156f3d32dddd483b8b3dbd95f" },
"friendly-snippets": { "branch": "main", "commit": "dcd4a586439a1c81357d5b9d26319ae218cc9479" }, "friendly-snippets": { "branch": "main", "commit": "dcd4a586439a1c81357d5b9d26319ae218cc9479" },
"fzy-lua-native": { "branch": "master", "commit": "820f745b7c442176bcc243e8f38ef4b985febfaf" }, "fzy-lua-native": { "branch": "master", "commit": "820f745b7c442176bcc243e8f38ef4b985febfaf" },
"git-blame.nvim": { "branch": "master", "commit": "a0282d05adbee80aaf4e2ff35b81b52940b67bed" }, "git-blame.nvim": { "branch": "master", "commit": "a0282d05adbee80aaf4e2ff35b81b52940b67bed" },
"github-nvim-theme": { "branch": "main", "commit": "d92e1143e5aaa0d7df28a26dd8ee2102df2cadd8" }, "github-nvim-theme": { "branch": "main", "commit": "d92e1143e5aaa0d7df28a26dd8ee2102df2cadd8" },
"gitsigns.nvim": { "branch": "main", "commit": "6ef8c54fb526bf3a0bc4efb0b2fe8e6d9a7daed2" }, "gitsigns.nvim": { "branch": "main", "commit": "6ef8c54fb526bf3a0bc4efb0b2fe8e6d9a7daed2" },
"go.nvim": { "branch": "master", "commit": "00f154ccd27e4ea497d9f242535f49d34b27aecb" }, "go.nvim": { "branch": "master", "commit": "9ac3e6faa32d01479973f4ca368d00b7ae328646" },
"guihua.lua": { "branch": "master", "commit": "9fb6795474918b492d9ab01b1ebaf85e8bf6fe0b" }, "guihua.lua": { "branch": "master", "commit": "9fb6795474918b492d9ab01b1ebaf85e8bf6fe0b" },
"indent-blankline.nvim": { "branch": "master", "commit": "821a7acd88587d966f7e464b0b3031dfe7f5680c" }, "indent-blankline.nvim": { "branch": "master", "commit": "3d08501caef2329aba5121b753e903904088f7e6" },
"karen-yank.nvim": { "branch": "main", "commit": "817f50c9464ce557c8f7f8f4d4c8d2f7b81fc40c" }, "karen-yank.nvim": { "branch": "main", "commit": "817f50c9464ce557c8f7f8f4d4c8d2f7b81fc40c" },
"lazy.nvim": { "branch": "main", "commit": "83493db50a434a4c5c648faf41e2ead80f96e478" }, "lazy.nvim": { "branch": "main", "commit": "83493db50a434a4c5c648faf41e2ead80f96e478" },
"leap.nvim": { "branch": "main", "commit": "89d878f8399d00fb348ad65b6077b996808234d8" }, "leap.nvim": { "branch": "main", "commit": "812604b7b100e555062fa41c82bfd9c6c776d856" },
"lspsaga.nvim": { "branch": "main", "commit": "7cabe9468b48c8dbd4ba84536610c6ddf9b38dae" }, "logstash.vim": { "branch": "master", "commit": "531fe079e8c964d2b5786bcb5871c72f966adc2a" },
"lspsaga.nvim": { "branch": "main", "commit": "01dc5ea5916abbe3158d2661e21d90dcc04d7c47" },
"lualine-lsp-progress": { "branch": "master", "commit": "56842d097245a08d77912edf5f2a69ba29f275d7" }, "lualine-lsp-progress": { "branch": "master", "commit": "56842d097245a08d77912edf5f2a69ba29f275d7" },
"lualine.nvim": { "branch": "master", "commit": "8b56462bfb746760465264de41b4907310f113ec" }, "lualine.nvim": { "branch": "master", "commit": "af4c3cf17206810880d2a93562e0a4c0d901c684" },
"markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" }, "markdown-preview.nvim": { "branch": "master", "commit": "a923f5fc5ba36a3b17e289dc35dc17f66d0548ee" },
"mason-lspconfig.nvim": { "branch": "main", "commit": "21d33d69a81f6351e5a5f49078b2e4f0075c8e73" }, "mason-lspconfig.nvim": { "branch": "main", "commit": "82c7cb08ddb836ad938b2708e50085f12a8825d2" },
"mason.nvim": { "branch": "main", "commit": "3b5068f0fc565f337d67a2d315d935f574848ee7" }, "mason.nvim": { "branch": "main", "commit": "3b5068f0fc565f337d67a2d315d935f574848ee7" },
"mini.align": { "branch": "main", "commit": "f845218c5fea89e49074e48270dc5e1b9511a0f9" }, "mini.align": { "branch": "main", "commit": "f845218c5fea89e49074e48270dc5e1b9511a0f9" },
"mini.starter": { "branch": "main", "commit": "ce222a5b6de50a9963c1eb62aa16ec6d5efca7ee" }, "mini.starter": { "branch": "main", "commit": "ce222a5b6de50a9963c1eb62aa16ec6d5efca7ee" },
"neo-tree.nvim": { "branch": "v2.x", "commit": "459c60317cc1d251f6eb3b6f010d015d5d24b806" }, "neo-tree.nvim": { "branch": "v2.x", "commit": "742db4e60c74e5fbcc596aaf9e7575e1342dfd09" },
"neotest": { "branch": "master", "commit": "4440cc2227894c2ae9b0673a30e6cc6f1836e8c2" }, "neotest": { "branch": "master", "commit": "4440cc2227894c2ae9b0673a30e6cc6f1836e8c2" },
"neotest-go": { "branch": "main", "commit": "6a2f996d89fe4631942e035b1c114544ee045043" }, "neotest-go": { "branch": "main", "commit": "6a2f996d89fe4631942e035b1c114544ee045043" },
"neovim-project": { "branch": "main", "commit": "e7868b38f402be94e859d479002df1418bc1e954" }, "neotest-python": { "branch": "master", "commit": "2e83d2bc00acbcc1fd529dbf0a0e677cabfe6b50" },
"neovim-project": { "branch": "main", "commit": "d7a91b6b86f3b5ff2d47c2ef920bc362e581ac48" },
"neovim-session-manager": { "branch": "master", "commit": "d8e1ba3bbcf3fdc6a887bcfbd94c48ae4707b457" }, "neovim-session-manager": { "branch": "master", "commit": "d8e1ba3bbcf3fdc6a887bcfbd94c48ae4707b457" },
"noice.nvim": { "branch": "main", "commit": "bf67d70bd7265d075191e7812d8eb42b9791f737" }, "noice.nvim": { "branch": "main", "commit": "bf67d70bd7265d075191e7812d8eb42b9791f737" },
"none-ls.nvim": { "branch": "main", "commit": "ff3819c52ca04232fb70fbd6c1639de9abcbe122" }, "none-ls.nvim": { "branch": "main", "commit": "72e25ed4162474ef5d666525853f8a42bffd97c5" },
"nui.nvim": { "branch": "main", "commit": "756c59f46057cd2d43619cd3a6d4e01b2aa60295" }, "nui.nvim": { "branch": "main", "commit": "3dc46d725f7b94bee5117c0a699b57b1902b5d65" },
"nvim-autopairs": { "branch": "master", "commit": "c6139ca0d5ad7af129ea6c89cb4c56093f2c034a" }, "nvim-autopairs": { "branch": "master", "commit": "c6139ca0d5ad7af129ea6c89cb4c56093f2c034a" },
"nvim-cmp": { "branch": "main", "commit": "04e0ca376d6abdbfc8b52180f8ea236cbfddf782" }, "nvim-cmp": { "branch": "main", "commit": "04e0ca376d6abdbfc8b52180f8ea236cbfddf782" },
"nvim-dap": { "branch": "master", "commit": "9d81c11fd185a131f81841e64941859305f6c42d" }, "nvim-dap": { "branch": "master", "commit": "9d81c11fd185a131f81841e64941859305f6c42d" },
"nvim-dap-python": { "branch": "master", "commit": "66560f0ebddf96604f7037e1efad3ba6942761e6" }, "nvim-dap-python": { "branch": "master", "commit": "66560f0ebddf96604f7037e1efad3ba6942761e6" },
"nvim-dap-ui": { "branch": "master", "commit": "0b4816e5ad5f3219e8e3ec9cce07f61b770c1974" }, "nvim-dap-ui": { "branch": "master", "commit": "0b4816e5ad5f3219e8e3ec9cce07f61b770c1974" },
"nvim-dap-virtual-text": { "branch": "master", "commit": "a5fc69240869c0fee8ff176bc9e4efdf8bdfb596" }, "nvim-dap-virtual-text": { "branch": "master", "commit": "baa5b0dc6663284cce32e0d00ac1f2511b13496f" },
"nvim-lspconfig": { "branch": "master", "commit": "94cf4adb81158817520e18d2174963d8e1424df9" }, "nvim-lspconfig": { "branch": "master", "commit": "1f3ef31d1bb967050c81420ca921a1a2ade10e77" },
"nvim-treesitter": { "branch": "master", "commit": "57205313dda0ac82ac69e21d5e2a80f3297c14cc" }, "nvim-treesitter": { "branch": "master", "commit": "bb3dd60ebcf6f75f73f39c44724b4a426ece6b7b" },
"nvim-ts-context-commentstring": { "branch": "main", "commit": "7ab799a9792f7cf3883cf28c6a00ad431f3d382a" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "7ab799a9792f7cf3883cf28c6a00ad431f3d382a" },
"nvim-ufo": { "branch": "main", "commit": "239ae620d818ffa1319ca3056546df71906d4bfb" }, "nvim-ufo": { "branch": "main", "commit": "2296dbb8939c4050c222f4eb24889540ef8acd76" },
"nvim-web-devicons": { "branch": "master", "commit": "4adea17610d140a99c313e3f79a9dc01825d59ae" }, "nvim-web-devicons": { "branch": "master", "commit": "cb0c967c9723a76ccb1be0cc3a9a10e577d2f6ec" },
"plenary.nvim": { "branch": "master", "commit": "f7adfc4b3f4f91aab6caebf42b3682945fbc35be" }, "plenary.nvim": { "branch": "master", "commit": "f7adfc4b3f4f91aab6caebf42b3682945fbc35be" },
"promise-async": { "branch": "main", "commit": "93540c168c5ed2b030ec3e6c40ab8bbb85e36355" }, "promise-async": { "branch": "main", "commit": "93540c168c5ed2b030ec3e6c40ab8bbb85e36355" },
"rose-pine": { "branch": "main", "commit": "c52167563e6aa44b5fa6fe007faa2bcac71050f0" },
"statuscol.nvim": { "branch": "main", "commit": "d954893262a57a92e46edd87de67e2b3fe72305e" }, "statuscol.nvim": { "branch": "main", "commit": "d954893262a57a92e46edd87de67e2b3fe72305e" },
"telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" },
"telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" }, "telescope-ui-select.nvim": { "branch": "master", "commit": "6e51d7da30bd139a6950adf2a47fda6df9fa06d2" },
"telescope.nvim": { "branch": "master", "commit": "7472420f8734c710bd7009081cef9b97f08a3821" }, "telescope.nvim": { "branch": "master", "commit": "e9e01d699843af530ef4ad2c8679a7e273bb3dd1" },
"tokyonight.nvim": { "branch": "main", "commit": "610179f7f12db3d08540b6cc61434db2eaecbcff" }, "tokyonight.nvim": { "branch": "main", "commit": "c025baf23b62f044eff1f4ef561c45de636f0e32" },
"trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" },
"typescript-tools.nvim": { "branch": "master", "commit": "c43d9580c3ff5999a1eabca849f807ab33787ea7" }, "typescript-tools.nvim": { "branch": "master", "commit": "c43d9580c3ff5999a1eabca849f807ab33787ea7" },
"venv-selector.nvim": { "branch": "main", "commit": "93ee4ac249277571a90db5b50aae83d6f9d036f5" }, "venv-selector.nvim": { "branch": "main", "commit": "2ad34f36d498ff5193ea10f79c87688bd5284172" },
"vim-bbye": { "branch": "master", "commit": "25ef93ac5a87526111f43e5110675032dbcacf56" }, "vim-bbye": { "branch": "master", "commit": "25ef93ac5a87526111f43e5110675032dbcacf56" },
"vim-illuminate": { "branch": "master", "commit": "305bf07b919ac526deb5193280379e2f8b599926" }, "vim-illuminate": { "branch": "master", "commit": "305bf07b919ac526deb5193280379e2f8b599926" },
"vim-kitty-navigator": { "branch": "master", "commit": "20abf8613aa228a5def1ae02cd9da0f2d210352a" }, "vim-kitty-navigator": { "branch": "master", "commit": "20abf8613aa228a5def1ae02cd9da0f2d210352a" },
"vim-markdown-toc": { "branch": "master", "commit": "0e2c7cdc3ac1d067eb309a10220d001bb7be39cd" }, "vim-markdown-toc": { "branch": "master", "commit": "5acf680e820940b1bd78a501298ff953455b8d65" },
"vim-visual-multi": { "branch": "master", "commit": "fe1ec7e430013b83c8c2dee85ae496251b71e253" }, "vim-visual-multi": { "branch": "master", "commit": "fe1ec7e430013b83c8c2dee85ae496251b71e253" },
"yaml-companion.nvim": { "branch": "main", "commit": "4de1e1546abc461f62dee02fcac6a02debd6eb9e" } "yaml-companion.nvim": { "branch": "main", "commit": "4de1e1546abc461f62dee02fcac6a02debd6eb9e" }
} }

View File

@ -153,11 +153,13 @@ keymap(
) )
-- Copilot -- Copilot
keymap("n", "<leader>coa", function() keymap({ "n", "v" }, "<leader>coa", function()
require("CopilotChat.code_actions").show_help_actions() local actions = require("CopilotChat.actions")
require("CopilotChat.integrations.telescope").pick(actions.help_actions())
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Help actions" })) end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Help actions" }))
keymap("n", "<leader>cop", function() keymap("n", "<leader>coh", function()
require("CopilotChat.code_actions").show_prompt_actions() local actions = require("CopilotChat.actions")
require("CopilotChat.integrations.telescope").pick(actions.prompt_actions())
end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Prompt actions" })) end, vim.tbl_extend("force", opts, { desc = "CopilotChat - Prompt actions" }))
-- Better paste -- Better paste

View File

@ -96,7 +96,14 @@ require("lazy").setup({
}, },
} }
require("github-theme").setup({ options = options, specs = specs }) require("github-theme").setup({ options = options, specs = specs })
vim.cmd("colorscheme github_dark_dimmed") end,
},
{
"rose-pine/neovim",
name = "rose-pine",
lazy = false,
config = function()
vim.cmd("colorscheme rose-pine-moon")
end, end,
}, },
@ -256,6 +263,7 @@ require("lazy").setup({
"nvim-neotest/neotest", "nvim-neotest/neotest",
dependencies = { dependencies = {
"nvim-neotest/neotest-go", "nvim-neotest/neotest-go",
"nvim-neotest/neotest-python",
"antoinemadec/FixCursorHold.nvim", "antoinemadec/FixCursorHold.nvim",
}, },
}, },
@ -288,6 +296,7 @@ require("lazy").setup({
{ "AndreM222/copilot-lualine" }, { "AndreM222/copilot-lualine" },
{ {
"copilotc-nvim/copilotchat.nvim", "copilotc-nvim/copilotchat.nvim",
branch = "canary",
event = "VeryLazy", event = "VeryLazy",
}, },
@ -317,4 +326,6 @@ require("lazy").setup({
}, },
}, },
}, },
{ "robbles/logstash.vim" },
}, lazy_opts) }, lazy_opts)

View File

@ -14,25 +14,16 @@ require("copilot").setup({
}, },
}) })
require("copilot_cmp").setup()
local prompts = { local prompts = {
-- Code related prompts Spelling = {
Explain = "Please explain how the following code works.", prompt = "/Spelling Please correct any grammar and spelling errors in the following text. Respect the markdown format when provided",
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("copilot_cmp").setup()
require("CopilotChat").setup({ require("CopilotChat").setup({
show_help = "yes",
debug = false, debug = false,
disable_extra_info = "yes", show_user_selection = false,
clear_chat_on_new_prompt = "yes", clear_chat_on_new_prompt = true,
prompts = prompts, prompts = prompts,
temperature = 0.1,
}) })

View File

@ -1,4 +1,5 @@
return { return {
cmd = { "/home/dani/.local/pipx/venvs/basedpyright/bin/basedpyright-langserver", "--stdio" },
settings = { settings = {
python = { python = {
analysis = { analysis = {

View File

@ -26,6 +26,7 @@ neotest.setup({
}, },
args = { "-count=1" }, args = { "-count=1" },
}), }),
require("neotest-python")({}),
}, },
}) })

View File

@ -3,7 +3,7 @@
URL=${1:-1.0.0.1} URL=${1:-1.0.0.1}
output=$(fping --quiet --outage --count=5 "$URL" 2>&1) output=$(fping --quiet --outage --count=5 "$URL" 2>&1)
outage_output="" outage_output=""
outage_color="FFFFFF" outage_color="FFFFFF"
avg_output="" avg_output=""
avg_color="FFFFFF" avg_color="FFFFFF"