old options
This commit is contained in:
parent
e73936f278
commit
4c5a9a157c
4
nvim/lua/kanopo/init.lua
Normal file
4
nvim/lua/kanopo/init.lua
Normal file
@ -0,0 +1,4 @@
|
||||
require('kanopo.pack')
|
||||
require('kanopo.options')
|
||||
|
||||
require('kanopo.plugins.gruvbox')
|
||||
65
nvim/lua/kanopo/options.lua
Normal file
65
nvim/lua/kanopo/options.lua
Normal file
@ -0,0 +1,65 @@
|
||||
require('vim._core.ui1').enable()
|
||||
|
||||
-- Leader keys (set early)
|
||||
vim.g.mapleader = " "
|
||||
vim.g.maplocalleader = " "
|
||||
|
||||
-- UI and appearance
|
||||
vim.o.termguicolors = true -- 24-bit colors in TUI
|
||||
vim.o.cursorline = true -- highlight current line
|
||||
vim.o.number = true -- absolute line numbers
|
||||
vim.o.relativenumber = true -- relative line numbers
|
||||
vim.o.signcolumn = "yes" -- always show signcolumn
|
||||
vim.o.colorcolumn = "100" -- visual column guide
|
||||
vim.o.winborder = "rounded" -- default floating window border
|
||||
vim.o.cmdheight = 0 -- minimal command-line height (NVIM 0.10+)
|
||||
vim.o.conceallevel = 2 -- conceal in Markdown/jsonc when appropriate
|
||||
vim.o.foldlevel = 0 -- start with folds closed (Treesitter can open)
|
||||
|
||||
-- Splits
|
||||
vim.o.splitright = true -- open vertical splits to the right
|
||||
vim.o.splitbelow = true -- open horizontal splits below
|
||||
|
||||
-- Editing behavior
|
||||
vim.o.wrap = false -- do not wrap lines by default
|
||||
vim.o.breakindent = true -- keep indentation on wrapped lines (if wrap is enabled later)
|
||||
vim.o.clipboard = "unnamedplus"
|
||||
vim.o.swapfile = false -- no swapfiles
|
||||
vim.o.undofile = true -- persistent undo
|
||||
vim.o.writebackup = false -- do not keep backup around
|
||||
|
||||
-- Tabs and indentation (2-space default; override per-filetype with autocmds)
|
||||
vim.o.expandtab = true
|
||||
vim.o.tabstop = 2
|
||||
vim.o.softtabstop = 2
|
||||
vim.o.shiftwidth = 2
|
||||
|
||||
-- Search
|
||||
vim.o.ignorecase = true -- case-insensitive
|
||||
vim.o.smartcase = true -- unless uppercase is used
|
||||
|
||||
-- Completion UX (good defaults for omni and popup behavior)
|
||||
vim.o.completeopt = "menu,menuone,noinsert,noselect"
|
||||
-- vim.o.shortmess = (vim.o.shortmess or "") .. "c" -- reduce completion messages
|
||||
|
||||
-- Performance and input timing
|
||||
vim.o.timeoutlen = 300 -- mapped sequence timeout
|
||||
vim.o.updatetime = 250 -- faster CursorHold/diagnostic updates
|
||||
vim.o.scrolloff = 10 -- context lines around cursor
|
||||
|
||||
-- Fonts/icons (used by statuslines/UIs)
|
||||
vim.g.have_nerd_font = true
|
||||
|
||||
|
||||
-- Netrw (disable if using an explorer plugin like oil.nvim; enable if you rely on netrw)
|
||||
vim.g.loaded_netrw = 0
|
||||
vim.g.loaded_netrwPlugin = 0
|
||||
|
||||
vim.o.mouse = "a"
|
||||
vim.o.showmode = false
|
||||
vim.o.list = true
|
||||
vim.opt.listchars = { tab = "» ", trail = "·", nbsp = "␣" }
|
||||
|
||||
-- Preview substitutions live, as you type!
|
||||
vim.o.inccommand = "split"
|
||||
vim.o.confirm = true
|
||||
6
nvim/lua/kanopo/pack.lua
Normal file
6
nvim/lua/kanopo/pack.lua
Normal file
@ -0,0 +1,6 @@
|
||||
|
||||
vim.pack.add({
|
||||
{ src = "https://github.com/ellisonleao/gruvbox.nvim" },
|
||||
}, {
|
||||
confirm = false,
|
||||
})
|
||||
8
nvim/lua/kanopo/plugins/gruvbox.lua
Normal file
8
nvim/lua/kanopo/plugins/gruvbox.lua
Normal file
@ -0,0 +1,8 @@
|
||||
|
||||
local ok, gruvbox = pcall(require, "gruvbox")
|
||||
if ok then
|
||||
gruvbox.setup()
|
||||
vim.cmd.colorscheme("gruvbox")
|
||||
else
|
||||
vim.notify(gruvbox, vim.log.levels.ERROR)
|
||||
end
|
||||
Loading…
x
Reference in New Issue
Block a user