1
Fork 0

An attempt at setting up neorg

This commit is contained in:
Matei Adriel 2023-04-17 22:01:50 +03:00
parent f2310011c0
commit f59c523e6f
No known key found for this signature in database
2 changed files with 56 additions and 0 deletions

View file

@ -37,6 +37,8 @@
"neoconf.nvim": { "branch": "main", "commit": "bc531ca41ba55d87416b4b3ade606ff81236389b" },
"neodev.nvim": { "branch": "main", "commit": "0a8e312923671e78499b2e204f0f678379ba92c1" },
"neogit": { "branch": "master", "commit": "039ff3212ec43cc4d3332956dfb54e263c8d5033" },
"neorg": { "branch": "main", "commit": "1fecaab548161abd0238b3d16c81e69c7d14252a" },
"neorg-telescope": { "branch": "main", "commit": "7d9f89375421401c41c3c270a2acad0b44ee0331" },
"nui.nvim": { "branch": "main", "commit": "0dc148c6ec06577fcf06cbab3b7dac96d48ba6be" },
"null-ls.nvim": { "branch": "main", "commit": "13dd1fc13063681ca7e039436c88f6eca7e3e937" },
"nvim-autopairs": { "branch": "master", "commit": "e755f366721bc9e189ddecd39554559045ac0a18" },

View file

@ -0,0 +1,54 @@
local M = {
"nvim-neorg/neorg",
build = ":Neorg sync-parsers",
dependencies = { "nvim-lua/plenary.nvim", "nvim-neorg/neorg-telescope" },
ft = "norg",
config = function()
require("neorg").setup({
load = {
["core.defaults"] = {}, -- Loads default behaviour
["core.norg.concealer"] = {}, -- Adds pretty icons to your documents
["core.integrations.telescope"] = {},
-- {{{ Completions
["core.norg.completion"] = {
config = {
engine = "nvim-cmp",
},
},
-- }}}
-- {{{ Dirman
["core.norg.dirman"] = { -- Manages Neorg workspaces
config = {
workspaces = {
notes = "~/Neorg",
["uni-notes"] = "~/Projects/uni-notes",
},
},
},
-- }}}
-- {{{ Keybinds
["core.keybinds"] = {
config = {
hook = function(keybinds)
-- Binds the `gtd` key in `norg` mode to execute `:echo 'Hello'`
keybinds.map("norg", "n", "gtd", "<cmd>echo 'Hello!'<CR>")
end,
},
},
-- }}}
},
})
-- {{{ Lazy cmp loading
vim.api.nvim_create_autocmd("InsertEnter", {
group = vim.api.nvim_create_augroup("CmpSourceNeorg", {}),
pattern = "*.norg",
callback = function()
require("cmp").setup.buffer({ sources = { { name = "neorg" } } })
end,
})
-- }}}
end,
}
return M