From 6b25442329f76c0c16cdc62a65ef551190ec9972 Mon Sep 17 00:00:00 2001 From: Warwick Date: Thu, 14 Dec 2023 15:40:39 +0000 Subject: [PATCH] Added nvim-orgmode (requires 0.9+) --- lua/.luarc.json | 24 ++++++++++++++ lua/core/plugin_config/indent-blankline.lua | 6 ++-- lua/core/plugins.lua | 35 +++++++++++++++++++-- 3 files changed, 60 insertions(+), 5 deletions(-) create mode 100644 lua/.luarc.json diff --git a/lua/.luarc.json b/lua/.luarc.json new file mode 100644 index 0000000..771af76 --- /dev/null +++ b/lua/.luarc.json @@ -0,0 +1,24 @@ +{ + "workspace.library": [ + "/home/warwick/.config/nvim", + "/home/warwick/.local/share/nvim/lazy/lazy.nvim", + "/home/warwick/.local/share/nvim/lazy/nvim-treesitter", + "/home/warwick/.local/share/nvim/lazy/nvim-tree.lua", + "/home/warwick/.local/share/nvim/lazy/nvim-cmp", + "/home/warwick/.local/share/nvim/lazy/plenary.nvim", + "/home/warwick/.local/share/nvim/lazy/telescope.nvim", + "/home/warwick/.local/share/nvim/lazy/nvim-web-devicons", + "/home/warwick/.local/share/nvim/lazy/cmp-nvim-lsp", + "/home/warwick/.local/share/nvim/lazy/lualine.nvim", + "/home/warwick/.local/share/nvim/lazy/nvim-lspconfig", + "/home/warwick/.local/share/nvim/lazy/mason-lspconfig.nvim", + "/home/warwick/.local/share/nvim/lazy/gruvbox.nvim", + "/home/warwick/.local/share/nvim/lazy/mason.nvim", + "/usr/share/nvim/runtime", + "/usr/share/nvim/runtime/pack/dist/opt/matchit", + "/usr/lib/nvim", + "/home/warwick/.local/state/nvim/lazy/readme", + "/home/warwick/.local/share/nvim/lazy/cmp-nvim-lsp/after", + "${3rd}/luassert/library" + ] +} \ No newline at end of file diff --git a/lua/core/plugin_config/indent-blankline.lua b/lua/core/plugin_config/indent-blankline.lua index 370650e..64f2297 100644 --- a/lua/core/plugin_config/indent-blankline.lua +++ b/lua/core/plugin_config/indent-blankline.lua @@ -1,6 +1,6 @@ -require("indent_blankline").setup { +require("ibl").setup { -- for example, context is off by default, use this to turn it on - show_current_context = false, - show_current_context_start = false, + --show_current_context = false, + --show_current_context_start = false, } vim.cmd [[colorscheme gruvbox]] diff --git a/lua/core/plugins.lua b/lua/core/plugins.lua index 811fc0b..ec05712 100644 --- a/lua/core/plugins.lua +++ b/lua/core/plugins.lua @@ -33,7 +33,7 @@ local plugins = { vim.o.timeoutlen = 300 end, }, - "lukas-reineke/indent-blankline.nvim", + { "lukas-reineke/indent-blankline.nvim", main = "ibl", opts = {} }, -- fzf { 'nvim-telescope/telescope.nvim', @@ -62,7 +62,38 @@ local plugins = { build = "make install_jsregexp" }, 'saadparwaiz1/cmp_luasnip', - 'rafamadriz/friendly-snippets' + 'rafamadriz/friendly-snippets', + -- Org Mode + { + 'nvim-orgmode/orgmode', + dependencies = { + { 'nvim-treesitter/nvim-treesitter', lazy = true }, + }, + event = 'VeryLazy', + config = function() + -- Load treesitter grammar for org + require('orgmode').setup_ts_grammar() + + -- Setup treesitter + --require('nvim-treesitter.configs').setup({ + -- highlight = { + -- enable = true, + -- additional_vim_regex_highlighting = { 'org' }, + -- }, + -- ensure_installed = { 'org' }, + --}) + + -- Setup orgmode + require('orgmode').setup({ + org_agenda_files = '~/.vimwiki/**/*', + org_default_notes_file = '~/.vimwiki/refile.org', + }) + -- Setup nvim-cmp + require('cmp').setup({ + sources = { { name = 'orgmode' } } + }) + end, + } } local opts = {}