Compare commits

..

No commits in common. "1f52e22b17923848a292279324357f039b1b8c95" and "e4f3ceaa8640012a3b56841d10bc1574f65957a1" have entirely different histories.

12 changed files with 100 additions and 56 deletions

View file

@ -1,2 +1,2 @@
require("config")
require("plugins")
require("config.settings")
require("config.lazy")

6
lazy-lock.json Normal file
View file

@ -0,0 +1,6 @@
{
"gruvbox.nvim": { "branch": "main", "commit": "5e0a460d8e0f7f669c158dedd5f9ae2bcac31437" },
"lazy.nvim": { "branch": "main", "commit": "1ea3c4085785f460fb0e46d2fe1ee895f5f9e7c1" },
"nvim-lspconfig": { "branch": "master", "commit": "ac98db2f9f06a56498ec890a96928774eae412c3" },
"nvim-treesitter": { "branch": "master", "commit": "42fc28ba918343ebfd5565147a42a26580579482" }
}

View file

@ -1,3 +0,0 @@
require('config.settings')
require('config.keybindings')
require('config.pack')

View file

@ -1,6 +0,0 @@
-- setup leader and local leader
vim.g.mapleader = " "
vim.g.maplocalleader = ";"
-- source current file
vim.keymap.set("n", "<Leader> ", ":update<CR> :source<CR>")

45
lua/config/lazy.lua Normal file
View file

@ -0,0 +1,45 @@
-- 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)
--setup lazy.nvim
require("lazy").setup({
spec = {
-- import plugins from specific directory
{ import = "plugins" },
},
-- setup correct colorscheme
install = { colorscheme = { "gruvbox"} },
-- automatically check for plugin updates
checker = { enabled = true },
rocks = {
enabled = false
},
performance = {
rtp = {
disabled_plugins = {
"gzip",
"matchit",
"matchparen",
"netrwPlugin",
"tarPlugin",
"tohtml",
"tutor",
"zipPlugin",
},
},
},
})

View file

@ -1,5 +0,0 @@
vim.pack.add({
{src = "https://github.com/ellisonleao/gruvbox.nvim"},
{src = "https://github.com/nvim-treesitter/nvim-treesitter"},
{src = "https://github.com/neovim/nvim-lspconfig"},
})

View file

@ -26,5 +26,6 @@ vim.opt.inccommand = "split"
-- ignore case
vim.opt.ignorecase = true
-- disable neovim swap files
vim.opt.swapfile = false
-- setup leader and local leader
vim.g.mapleader = " "
vim.g.maplocalleader = ";"

View file

@ -1,2 +1,12 @@
vim.o.background = "dark"
vim.cmd([[colorscheme gruvbox]])
return {
{
"ellisonleao/gruvbox.nvim",
lazy = false,
priority = 1000,
config = function()
-- load colorscheme here
vim.o.background = "dark"
vim.cmd([[colorscheme gruvbox]])
end,
},
}

View file

@ -1 +0,0 @@
require("plugins.colorscheme")

View file

@ -1,3 +1,9 @@
vim.lsp.enable(
"nixd"
)
return {
{
"neovim/nvim-lspconfig",
config = function()
vim.lsp.enable("nixd")
end,
},
}

View file

@ -1,19 +1,26 @@
require("nvim-treesitter.configs").setup({
ensure_installed = { "c", "lua", "vim", "vimdoc", "query", "go", "nix" },
return {
{
"nvim-treesitter/nvim-treesitter",
config = function()
require("nvim-treesitter.configs").setup({
ensure_installed = { "c", "lua", "vim", "vimdoc", "query", "go", "nix" },
auto_install = true,
auto_install = true,
highlight = {
enable = true,
highlight = {
enable = true,
},
incremental_selection = {
enable = true,
keymaps = {
init_selection = "<Leader>ss",
node_incremental = "<Leader>si",
scope_incremental = "<Leader>sc",
node_decremental = "<Leader>sd",
},
},
})
end,
},
incremental_selection = {
enable = true,
keymaps = {
init_selection = "<Leader>ss",
node_incremental = "<Leader>si",
scope_incremental = "<Leader>sc",
node_decremental = "<Leader>sd",
},
},
})
}

View file

@ -1,16 +0,0 @@
{
"plugins": {
"gruvbox.nvim": {
"rev": "5e0a460",
"src": "https://github.com/ellisonleao/gruvbox.nvim"
},
"nvim-lspconfig": {
"rev": "ac98db2",
"src": "https://github.com/neovim/nvim-lspconfig"
},
"nvim-treesitter": {
"rev": "42fc28ba",
"src": "https://github.com/nvim-treesitter/nvim-treesitter"
}
}
}