diff --git a/init.lua b/init.lua index 6c6ae020..68a88928 100644 --- a/init.lua +++ b/init.lua @@ -193,13 +193,8 @@ require('lazy').setup({ -- Theme inspired by Atom 'navarasu/onedark.nvim', priority = 1000, - lazy = false, config = function() - require('onedark').setup { - -- Set a style preset. 'dark' is default. - style = 'dark', -- dark, darker, cool, deep, warm, warmer, light - } - require('onedark').load() + vim.cmd.colorscheme 'onedark' end, }, @@ -210,7 +205,7 @@ require('lazy').setup({ opts = { options = { icons_enabled = false, - theme = 'auto', + theme = 'onedark', component_separators = '|', section_separators = '', }, @@ -258,6 +253,7 @@ require('lazy').setup({ }, build = ':TSUpdate', }, + { 'ThePrimeagen/vim-be-good' }, -- NOTE: Next Step on Your Neovim Journey: Add/Configure additional "plugins" for kickstart -- These are some example plugins that I've included in the kickstart repository. @@ -315,6 +311,17 @@ vim.o.completeopt = 'menuone,noselect' -- NOTE: You should make sure your terminal supports this vim.o.termguicolors = true +-- my vim keybindings + +vim.o.nu = true +vim.o.relativenumber = true +vim.o.tabstop = 2 +vim.o.softtabstop = 2 +vim.o.shiftwidth = 2 +vim.o.expandtab = true + +vim.o.scrolloff = 10 + -- [[ Basic Keymaps ]] -- Keymaps for better default experience @@ -331,6 +338,15 @@ vim.keymap.set('n', ']d', vim.diagnostic.goto_next, { desc = 'Go to next diagnos vim.keymap.set('n', 'e', vim.diagnostic.open_float, { desc = 'Open floating diagnostic message' }) vim.keymap.set('n', 'q', vim.diagnostic.setloclist, { desc = 'Open diagnostics list' }) +-- my keymaps +-- ctrl u/d and center +vim.keymap.set('n', '', 'zz') +vim.keymap.set('n', '', 'zz') + +-- cursor in middle when search +vim.keymap.set('n', 'n', 'nzzzv') +vim.keymap.set('n', 'N', 'Nzzzv') + -- [[ Highlight on yank ]] -- See `:help vim.highlight.on_yank()` local highlight_group = vim.api.nvim_create_augroup('YankHighlight', { clear = true }) @@ -428,7 +444,7 @@ vim.keymap.set('n', 'sr', require('telescope.builtin').resume, { desc = vim.defer_fn(function() require('nvim-treesitter.configs').setup { -- Add languages to be installed here that you want installed for treesitter - ensure_installed = { 'c', 'cpp', 'go', 'lua', 'python', 'rust', 'tsx', 'javascript', 'typescript', 'vimdoc', 'vim', 'bash' }, + ensure_installed = { 'c', 'cpp', 'go', 'lua', 'python', 'rust', 'tsx', 'javascript', 'typescript', 'vimdoc', 'vim', 'bash', 'ruby' }, -- Autoinstall languages that are not installed. Defaults to false (but you can change for yourself!) auto_install = false,