From d619d03e560def920cf159dfeb81803917a0cd54 Mon Sep 17 00:00:00 2001 From: dlond Date: Mon, 26 May 2025 04:47:46 +1200 Subject: [PATCH] trying to fix auto indenting again --- init.lua | 11 ++++++----- lua/custom/options.lua | 7 ++++--- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/init.lua b/init.lua index 9af8960d..b27ccf4e 100644 --- a/init.lua +++ b/init.lua @@ -219,9 +219,6 @@ vim.api.nvim_create_autocmd('TextYankPost', { end, }) -require 'custom.options' -require 'custom.keymaps' - -- [[ Install `lazy.nvim` plugin manager ]] -- See `:help lazy.nvim.txt` or https://github.com/folke/lazy.nvim for more info local lazypath = vim.fn.stdpath 'data' .. '/lazy/lazy.nvim' @@ -301,7 +298,7 @@ require('lazy').setup({ -- Then, because we use the `opts` key (recommended), the configuration runs -- after the plugin has been loaded as `require(MODULE).setup(opts)`. - { -- Useful plugin to show you pending keybinds. + { -- Useful plugin to show you pending keybinds. 'folke/which-key.nvim', event = 'VimEnter', -- Sets the loading event to 'VimEnter' opts = { @@ -382,7 +379,7 @@ require('lazy').setup({ { 'nvim-telescope/telescope-ui-select.nvim' }, -- Useful for getting pretty icons, but requires a Nerd Font. - { 'nvim-tree/nvim-web-devicons', enabled = vim.g.have_nerd_font }, + { 'nvim-tree/nvim-web-devicons', enabled = vim.g.have_nerd_font }, }, config = function() -- Telescope is a fuzzy finder that comes with a lot of different things that @@ -971,5 +968,9 @@ require('lazy').setup({ }, }) +require 'custom.options' +require 'custom.keymaps' +require 'custom.utils' + -- The line beneath this is called `modeline`. See `:help modeline` -- vim: ts=2 sts=2 sw=2 et diff --git a/lua/custom/options.lua b/lua/custom/options.lua index 6bb32e88..4b7a7fb2 100644 --- a/lua/custom/options.lua +++ b/lua/custom/options.lua @@ -4,11 +4,12 @@ vim.g.have_nerd_font = true -- Indentation settings -vim.o.expandtab = true vim.o.smartindent = true vim.o.autoindent = true -vim.o.tabstop = 4 -vim.o.shiftwidth = 4 +vim.o.expandtab = true +vim.o.tabstop = 2 +vim.o.shiftwidth = 2 +vim.o.softtabstop = 2 -- Add any other custom vim.o or vim.g settings from your old config here -- For example, if you changed defaults for: