feat(init): better tabs

This commit is contained in:
Paul Fey 2025-03-31 18:23:36 +02:00
parent 66ee14e884
commit 9e6a2d32b5

View file

@ -1,14 +1,15 @@
-- Bootstrap lazy.nvim -- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git" local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) local out = vim.fn.system({
"git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo,
lazypath
})
if vim.v.shell_error ~= 0 then if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({ vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" }, {"Failed to clone lazy.nvim:\n", "ErrorMsg"}, {out, "WarningMsg"},
{ out, "WarningMsg" }, {"\nPress any key to exit..."}
{ "\nPress any key to exit..." },
}, true, {}) }, true, {})
vim.fn.getchar() vim.fn.getchar()
os.exit(1) os.exit(1)
@ -24,11 +25,15 @@ vim.g.maplocalleader = "\\"
local opts = { local opts = {
rocks = { rocks = {
hererocks = false, -- recommended if you do not have global installation of Lua 5.1. hererocks = false -- recommended if you do not have global installation of Lua 5.1.
}, }
} }
-- Setup lazy.nvim -- Setup lazy.nvim
require("lazy").setup("plugins", opts) require("lazy").setup("plugins", opts)
vim.cmd("set expandtab")
vim.cmd("set tabstop=2")
vim.cmd("set softtabstop=2")
vim.cmd("set shiftwidth=2")
vim.cmd('set number') vim.cmd('set number')