dotfiles

Personal dotfiles.
git clone git://vcs.sapka.me/dotfiles
Log | Files | Refs | Submodules

commit 0492a2d088a32904ce13fe3a0c0ad58497f50503
parent 212e56eb8e8e107fd1975009258f7c73e167f42b
Author: MichaƂ M. Sapka <michal@sapka.me>
Date:   Tue, 24 May 2022 15:41:26 +0200

Add Neorg

Diffstat:
Mnvim/init.lua | 12+++++++++++-
Mnvim/lua/user/lsp/configs.lua | 2+-
Anvim/lua/user/neorg.lua | 20++++++++++++++++++++
Mnvim/lua/user/treesitter.lua | 2+-
Mnvim/plugin/packer_compiled.lua | 53+++++++++++++++++++++++++++++------------------------
5 files changed, 62 insertions(+), 27 deletions(-)

diff --git a/nvim/init.lua b/nvim/init.lua @@ -202,6 +202,7 @@ cmp.setup { require "user.lsp" require "user.treesitter" +require "user.neorg" -- Install your plugins here @@ -249,11 +250,20 @@ return packer.startup(function(use) use "jose-elias-alvarez/null-ls.nvim" -- for formatters and linters --treesitter - use { + use { "nvim-treesitter/nvim-treesitter", run = 'TSUpdate' } + -- neorg + use { + "nvim-neorg/neorg", + after = "nvim-treesitter", -- Ensures that neorg loads after nvim-treesitter + requires = { + "nvim-lua/plenary.nvim" + } + } + -- Automatically set up your configuration after cloning packer.nvim -- Put this at the end after all plugins if PACKER_BOOTSTRAP then diff --git a/nvim/lua/user/lsp/configs.lua b/nvim/lua/user/lsp/configs.lua @@ -5,7 +5,7 @@ end local lspconfig = require("lspconfig") -local servers = { "jsonls", "sumneko_lua", "gopls" } +local servers = { "jsonls", "sumneko_lua", "gopls", "solargraph" } lsp_installer.setup { ensure_installed = servers diff --git a/nvim/lua/user/neorg.lua b/nvim/lua/user/neorg.lua @@ -0,0 +1,20 @@ +local status_ok, configs = pcall(require, "neorg") +if not status_ok then + return +end + +configs.setup { + load = { + ["core.defaults"] = {}, + ["core.norg.dirman"] = { + config = { + workspaces = { + work = "~/notes/work", + home = "~/notes/home", + }, + autochdir = true, -- Automatically change the directory to the current workspace's root every time + index = "index.norg", -- The name of the main (root) .norg file + } + } + } +} diff --git a/nvim/lua/user/treesitter.lua b/nvim/lua/user/treesitter.lua @@ -4,7 +4,7 @@ if not status_ok then end configs.setup { - ensure_installed = {"html", "ruby", "go", "javascript", "bash", "java", "json", "tsx", "lua" }, + ensure_installed = {"html", "ruby", "go", "javascript", "bash", "java", "json", "tsx", "lua", "norg" }, sync_install = false, -- install languages synchronously (only applied to `ensure_installed`) ignore_install = { "" }, -- List of parsers to ignore installing autopairs = { diff --git a/nvim/plugin/packer_compiled.lua b/nvim/plugin/packer_compiled.lua @@ -44,8 +44,8 @@ local function save_profiles(threshold) end time([[Luarocks path setup]], true) -local package_path_str = "/home/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/home/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/home/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/home/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua" -local install_cpath_pattern = "/home/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so" +local package_path_str = "/Users/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?.lua;/Users/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/share/lua/5.1/?/init.lua;/Users/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?.lua;/Users/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/luarocks/rocks-5.1/?/init.lua" +local install_cpath_pattern = "/Users/msapka/.cache/nvim/packer_hererocks/2.1.0-beta3/lib/lua/5.1/?.so" if not string.find(package.path, package_path_str, 1, true) then package.path = package.path .. ';' .. package_path_str end @@ -71,113 +71,118 @@ time([[Defining packer_plugins]], true) _G.packer_plugins = { LuaSnip = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/LuaSnip", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/LuaSnip", url = "https://github.com/L3MON4D3/LuaSnip" }, ["cmp-buffer"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/cmp-buffer", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/cmp-buffer", url = "https://github.com/hrsh7th/cmp-buffer" }, ["cmp-cmdline"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/cmp-cmdline", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/cmp-cmdline", url = "https://github.com/hrsh7th/cmp-cmdline" }, ["cmp-nvim-lsp"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/cmp-nvim-lsp", url = "https://github.com/hrsh7th/cmp-nvim-lsp" }, ["cmp-path"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/cmp-path", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/cmp-path", url = "https://github.com/hrsh7th/cmp-path" }, cmp_luasnip = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/cmp_luasnip", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/cmp_luasnip", url = "https://github.com/saadparwaiz1/cmp_luasnip" }, ["dracula.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/dracula.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/dracula.nvim", url = "https://github.com/Mofiqul/dracula.nvim" }, ["friendly-snippets"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/friendly-snippets", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/friendly-snippets", url = "https://github.com/rafamadriz/friendly-snippets" }, ["gitsigns.nvim"] = { config = { "\27LJ\2\n6\0\0\3\0\3\0\0066\0\0\0'\2\1\0B\0\2\0029\0\2\0B\0\1\1K\0\1\0\nsetup\rgitsigns\frequire\0" }, loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/gitsigns.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/gitsigns.nvim", url = "https://github.com/lewis6991/gitsigns.nvim" }, ["lualine.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/lualine.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/lualine.nvim", url = "https://github.com/nvim-lualine/lualine.nvim" }, + neorg = { + loaded = true, + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/neorg", + url = "https://github.com/nvim-neorg/neorg" + }, ["nlsp-settings.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nlsp-settings.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nlsp-settings.nvim", url = "https://github.com/tamago324/nlsp-settings.nvim" }, ["null-ls.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/null-ls.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/null-ls.nvim", url = "https://github.com/jose-elias-alvarez/null-ls.nvim" }, ["nvim-cmp"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-cmp", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-cmp", url = "https://github.com/hrsh7th/nvim-cmp" }, ["nvim-lsp-installer"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-lsp-installer", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-lsp-installer", url = "https://github.com/williamboman/nvim-lsp-installer" }, ["nvim-lspconfig"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-lspconfig", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-lspconfig", url = "https://github.com/neovim/nvim-lspconfig" }, ["nvim-tree.lua"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-tree.lua", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-tree.lua", url = "https://github.com/kyazdani42/nvim-tree.lua" }, ["nvim-treesitter"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-treesitter", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-treesitter", url = "https://github.com/nvim-treesitter/nvim-treesitter" }, ["nvim-web-devicons"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/nvim-web-devicons", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/nvim-web-devicons", url = "https://github.com/kyazdani42/nvim-web-devicons" }, ["packer.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/packer.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/packer.nvim", url = "https://github.com/wbthomason/packer.nvim" }, ["plenary.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/plenary.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/plenary.nvim", url = "https://github.com/nvim-lua/plenary.nvim" }, ["popup.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/popup.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/popup.nvim", url = "https://github.com/nvim-lua/popup.nvim" }, ["telescope.nvim"] = { loaded = true, - path = "/home/msapka/.local/share/nvim/site/pack/packer/start/telescope.nvim", + path = "/Users/msapka/.local/share/nvim/site/pack/packer/start/telescope.nvim", url = "https://github.com/nvim-telescope/telescope.nvim" } }