@@ -102,7 +102,7 @@ vim.g.have_nerd_font = false
102102vim .opt .number = true
103103-- You can also add relative line numbers, to help with jumping.
104104-- Experiment for yourself to see if you like it!
105- -- vim.opt.relativenumber = true
105+ vim .opt .relativenumber = true
106106
107107-- Enable mouse mode, can be useful for resizing splits for example!
108108vim .opt .mouse = ' a'
@@ -209,10 +209,7 @@ vim.api.nvim_create_autocmd('TextYankPost', {
209209local lazypath = vim .fn .stdpath ' data' .. ' /lazy/lazy.nvim'
210210if not vim .loop .fs_stat (lazypath ) then
211211 local lazyrepo = ' https://github.com/folke/lazy.nvim.git'
212- local out = vim .fn .system { ' git' , ' clone' , ' --filter=blob:none' , ' --branch=stable' , lazyrepo , lazypath }
213- if vim .v .shell_error ~= 0 then
214- error (' Error cloning lazy.nvim:\n ' .. out )
215- end
212+ vim .fn .system { ' git' , ' clone' , ' --filter=blob:none' , ' --branch=stable' , lazyrepo , lazypath }
216213end --- @diagnostic disable-next-line : undefined-field
217214vim .opt .rtp :prepend (lazypath )
218215
@@ -230,7 +227,7 @@ vim.opt.rtp:prepend(lazypath)
230227require (' lazy' ).setup ({
231228 -- NOTE: Plugins can be added with a link (or for a github repo: 'owner/repo' link).
232229 ' tpope/vim-sleuth' , -- Detect tabstop and shiftwidth automatically
233-
230+ ' github/copilot.vim ' ,
234231 -- NOTE: Plugins can also be added by using a table,
235232 -- with the first argument being the link and the following
236233 -- keys can be used to configure plugin behavior/loading/etc.
@@ -283,15 +280,19 @@ require('lazy').setup({
283280 require (' which-key' ).setup ()
284281
285282 -- Document existing key chains
286- require (' which-key' ).add {
287- { ' <leader>c' , group = ' [C]ode' },
288- { ' <leader>d' , group = ' [D]ocument' },
289- { ' <leader>r' , group = ' [R]ename' },
290- { ' <leader>s' , group = ' [S]earch' },
291- { ' <leader>w' , group = ' [W]orkspace' },
292- { ' <leader>t' , group = ' [T]oggle' },
293- { ' <leader>h' , group = ' Git [H]unk' , mode = { ' n ' , ' v ' } },
283+ require (' which-key' ).register {
284+ [ ' <leader>c' ] = { name = ' [C]ode' , _ = ' which_key_ignore ' },
285+ [ ' <leader>d' ] = { name = ' [D]ocument' , _ = ' which_key_ignore ' },
286+ [ ' <leader>r' ] = { name = ' [R]ename' , _ = ' which_key_ignore ' },
287+ [ ' <leader>s' ] = { name = ' [S]earch' , _ = ' which_key_ignore ' },
288+ [ ' <leader>w' ] = { name = ' [W]orkspace' , _ = ' which_key_ignore ' },
289+ [ ' <leader>t' ] = { name = ' [T]oggle' , _ = ' which_key_ignore ' },
290+ [ ' <leader>h' ] = { name = ' Git [H]unk' , _ = ' which_key_ignore ' },
294291 }
292+ -- visual mode
293+ require (' which-key' ).register ({
294+ [' <leader>h' ] = { ' Git [H]unk' },
295+ }, { mode = ' v' })
295296 end ,
296297 },
297298
@@ -564,10 +565,10 @@ require('lazy').setup({
564565 -- - settings (table): Override the default settings passed when initializing the server.
565566 -- For example, to see the options for `lua_ls`, you could go to: https://luals.github.io/wiki/settings/
566567 local servers = {
567- -- clangd = {},
568+ clangd = {},
568569 -- gopls = {},
569- -- pyright = {},
570- -- rust_analyzer = {},
570+ ruff = {},
571+ rust_analyzer = {},
571572 -- ... etc. See `:help lspconfig-all` for a list of all the pre-configured LSPs
572573 --
573574 -- Some languages (like typescript) have entire language plugins that can be useful:
@@ -651,9 +652,8 @@ require('lazy').setup({
651652 end ,
652653 formatters_by_ft = {
653654 lua = { ' stylua' },
655+ json = { ' jq' },
654656 -- Conform can also run multiple formatters sequentially
655- -- python = { "isort", "black" },
656- --
657657 -- You can use a sub-list to tell conform to run *until* a formatter
658658 -- is found.
659659 -- javascript = { { "prettierd", "prettier" } },
@@ -777,15 +777,33 @@ require('lazy').setup({
777777 -- change the command in the config to whatever the name of that colorscheme is.
778778 --
779779 -- If you want to see what colorschemes are already installed, you can use `:Telescope colorscheme`.
780- ' folke/tokyonight.nvim' ,
780+ ' rebelot/kanagawa.nvim' ,
781+ lazy = false ,
781782 priority = 1000 , -- Make sure to load this before all the other start plugins.
782- init = function ()
783- -- Load the colorscheme here.
784- -- Like many other themes, this one has different styles, and you could load
785- -- any other, such as 'tokyonight-storm', 'tokyonight-moon', or 'tokyonight-day'.
786- vim .cmd .colorscheme ' tokyonight-night'
787-
788- -- You can configure highlights by doing something like:
783+ config = function ()
784+ -- Default options:
785+ require (' kanagawa' ).setup {
786+ compile = false , -- enable compiling the colorscheme
787+ undercurl = true , -- enable undercurls
788+ commentStyle = { italic = true },
789+ functionStyle = {},
790+ keywordStyle = { italic = true },
791+ statementStyle = { bold = true },
792+ typeStyle = {},
793+ transparent = false , -- do not set background color
794+ dimInactive = false , -- dim inactive window `:h hl-NormalNC`
795+ terminalColors = true , -- define vim.g.terminal_color_{0,17}
796+ colors = { -- add/modify theme and palette colors
797+ palette = {},
798+ theme = { wave = {}, lotus = {}, dragon = {}, all = {} },
799+ },
800+ background = { -- map the value of 'background' option to a theme
801+ dark = ' wave' , -- try "dragon" !
802+ light = ' wave' ,
803+ },
804+ }
805+ -- setup must be called before loading
806+ vim .cmd ' colorscheme kanagawa-wave'
789807 vim .cmd .hi ' Comment gui=none'
790808 end ,
791809 },
@@ -834,7 +852,7 @@ require('lazy').setup({
834852 ' nvim-treesitter/nvim-treesitter' ,
835853 build = ' :TSUpdate' ,
836854 opts = {
837- ensure_installed = { ' bash' , ' c' , ' diff' , ' html' , ' lua' , ' luadoc' , ' markdown' , ' markdown_inline ' , ' query ' , ' vim ' , ' vimdoc ' },
855+ ensure_installed = { ' bash' , ' c' , ' diff' , ' html' , ' lua' , ' luadoc' , ' markdown' , ' vim ' , ' vimdoc ' , ' python ' , ' rust ' , ' zig ' },
838856 -- Autoinstall languages that are not installed
839857 auto_install = true ,
840858 highlight = {
@@ -862,6 +880,33 @@ require('lazy').setup({
862880 -- - Treesitter + textobjects: https://github.com/nvim-treesitter/nvim-treesitter-textobjects
863881 end ,
864882 },
883+ {
884+ ' cameron-wags/rainbow_csv.nvim' ,
885+ config = true ,
886+ ft = {
887+ ' csv' ,
888+ ' tsv' ,
889+ ' csv_semicolon' ,
890+ ' csv_whitespace' ,
891+ ' csv_pipe' ,
892+ ' rfc_csv' ,
893+ ' rfc_semicolon' ,
894+ },
895+ cmd = {
896+ ' RainbowDelim' ,
897+ ' RainbowDelimSimple' ,
898+ ' RainbowDelimQuoted' ,
899+ ' RainbowMultiDelim' ,
900+ },
901+ },
902+ {
903+ ' iamcco/markdown-preview.nvim' ,
904+ cmd = { ' MarkdownPreviewToggle' , ' MarkdownPreview' , ' MarkdownPreviewStop' },
905+ ft = { ' markdown' },
906+ build = function ()
907+ vim .fn [' mkdp#util#install' ]()
908+ end ,
909+ },
865910
866911 -- The following two comments only work if you have downloaded the kickstart repo, not just copy pasted the
867912 -- init.lua. If you want these files, they are in the repository, so you can just download them and
0 commit comments