-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathinit.lua
More file actions
60 lines (55 loc) · 1.62 KB
/
Copy pathinit.lua
File metadata and controls
60 lines (55 loc) · 1.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
-- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not vim.loop.fs_stat(lazypath) then
vim.fn.system({
"git",
"clone",
"--filter=blob:none",
"https://github.com/folke/lazy.nvim.git",
"--branch=stable",
lazypath,
})
end
vim.opt.rtp:prepend(lazypath)
-- Leader keys
vim.g.mapleader = " "
vim.g.maplocalleader = " "
vim.o.termguicolors = true
-- Load core configuration
require("core.options")
require("core.keymaps")
require("core.autocmds")
require("core.diagnostics")
require("core.norminette").setup()
require("core.semantic_tokens").setup()
require("core.rainbow_var").setup()
-- Setup lazy.nvim
require("lazy").setup("plugins", {
defaults = { lazy = true },
install = { colorscheme = { "tokyonight" } },
checker = { enabled = true },
performance = {
rtp = {
disabled_plugins = {
"gzip",
"tarPlugin",
"tohtml",
"tutor",
"zipPlugin",
},
},
},
})
-- Wallpaper-driven colorscheme (nvim/colors/wallpaper.lua, palette from
-- nvim/lua/colors_generated.lua, regenerated by sketchybar/theme/generate.sh
-- whenever the wallpaper changes). That file is gitignored (machine-
-- specific) -- on a fresh clone, or any machine that never ran sketchybar,
-- fall back to the real tokyonight-night (tokyonight.nvim is lazy=false,
-- so it's already loaded by this point). Checked after lazy.setup(), not
-- before: tokyonight-night wouldn't be resolvable yet otherwise.
local colors_generated = vim.fn.stdpath("config") .. "/lua/colors_generated.lua"
if vim.loop.fs_stat(colors_generated) then
vim.cmd.colorscheme("wallpaper")
else
vim.cmd.colorscheme("tokyonight-night")
end