initial commit
This commit is contained in:
commit
179e92ee04
17 changed files with 2377 additions and 0 deletions
35
lua/config/lazy.lua
Normal file
35
lua/config/lazy.lua
Normal file
|
|
@ -0,0 +1,35 @@
|
|||
-- Bootstrap lazy.nvim
|
||||
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
|
||||
if not (vim.uv or vim.loop).fs_stat(lazypath) then
|
||||
local lazyrepo = "https://github.com/folke/lazy.nvim.git"
|
||||
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
|
||||
if vim.v.shell_error ~= 0 then
|
||||
vim.api.nvim_echo({
|
||||
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" },
|
||||
{ out, "WarningMsg" },
|
||||
{ "\nPress any key to exit..." },
|
||||
}, true, {})
|
||||
vim.fn.getchar()
|
||||
os.exit(1)
|
||||
end
|
||||
end
|
||||
vim.opt.rtp:prepend(lazypath)
|
||||
|
||||
-- Make sure to setup `mapleader` and `maplocalleader` before
|
||||
-- loading lazy.nvim so that mappings are correct.
|
||||
-- This is also a good place to setup other settings (vim.opt)
|
||||
vim.g.mapleader = " "
|
||||
vim.g.maplocalleader = "\\"
|
||||
|
||||
require("settings")
|
||||
|
||||
-- Setup lazy.nvim
|
||||
require("lazy").setup({
|
||||
spec = {
|
||||
{ import = "plugins" },
|
||||
},
|
||||
checker = {
|
||||
enabled = true,
|
||||
notify = false,
|
||||
},
|
||||
})
|
||||
6
lua/plugins/theme.lua
Normal file
6
lua/plugins/theme.lua
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
return {
|
||||
"ellisonleao/gruvbox.nvim",
|
||||
priority = 1000,
|
||||
config = true,
|
||||
opts = ...,
|
||||
}
|
||||
33
lua/settings.lua
Normal file
33
lua/settings.lua
Normal file
|
|
@ -0,0 +1,33 @@
|
|||
-- Line numbers
|
||||
vim.opt.number = true -- show absolute line numbers
|
||||
vim.opt.relativenumber = true -- show relative line numbers
|
||||
|
||||
-- Mouse & clipboard
|
||||
vim.opt.mouse = "a" -- enable mouse support
|
||||
vim.opt.clipboard = "unnamedplus" -- use system clipboard
|
||||
|
||||
-- Visual behavior
|
||||
vim.opt.termguicolors = true -- enable true colors
|
||||
vim.opt.cursorline = true -- highlight the current line
|
||||
vim.opt.wrap = false -- do not wrap long lines
|
||||
vim.opt.signcolumn = "yes" -- always show the sign number (LSP, git)
|
||||
|
||||
-- Scrolling
|
||||
vim.opt.scrolloff = 8 -- keep space above/below cursor
|
||||
vim.opt.sidescrolloff = 8 -- keep space left/right of cursor
|
||||
|
||||
-- Indentation
|
||||
vim.opt.expandtab = true -- use spaces instead of tabs
|
||||
vim.opt.tabstop = 2 -- how many spaces a tab looks like
|
||||
vim.opt.shiftwidth = 2 -- how many spaces when indenting
|
||||
|
||||
-- Search
|
||||
vim.opt.ignorecase = true -- case-insensitive search
|
||||
vim.opt.smartcase = true -- case-sensitive if uppercase is used
|
||||
vim.opt.incsearch = true -- show matches while typing
|
||||
vim.opt.hlsearch = false -- do not keep matches highlighted
|
||||
|
||||
-- Window splits
|
||||
vim.opt.splitbelow = true -- horizontal splits open below
|
||||
vim.opt.splitright = true -- vertical splits open to the right
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue