diff --git a/dot_config/nvim/init.lua b/dot_config/nvim/init.lua index f46c8fe..e78b146 100644 --- a/dot_config/nvim/init.lua +++ b/dot_config/nvim/init.lua @@ -1,3 +1,4 @@ +require("core.options") if not vim.g.vscode then require("core.options") require("core.keymaps") diff --git a/dot_config/nvim/lua/config/lazy.lua b/dot_config/nvim/lua/config/lazy.lua index 7c1c935..8879377 100644 --- a/dot_config/nvim/lua/config/lazy.lua +++ b/dot_config/nvim/lua/config/lazy.lua @@ -1,18 +1,19 @@ --- 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 +if not vim.g.vscode then + -- 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) + require("lazy").setup("plugins") end -vim.opt.rtp:prepend(lazypath) - -require("lazy").setup("plugins") diff --git a/dot_config/nvim/lua/core/options.lua b/dot_config/nvim/lua/core/options.lua index f7e252d..07df8cf 100644 --- a/dot_config/nvim/lua/core/options.lua +++ b/dot_config/nvim/lua/core/options.lua @@ -1,8 +1,5 @@ local opt = vim.opt --- appearence -opt.guicursor = "" - -- clipboard opt.clipboard:append("unnamedplus") opt.scrolloff = 8 @@ -12,6 +9,8 @@ opt.incsearch = true opt.hlsearch = false if not vim.g.vscode then + -- appearence + opt.guicursor = "" -- line numbers opt.nu = true opt.relativenumber = true