-
-
Notifications
You must be signed in to change notification settings - Fork 214
Metagen
github-actions[bot] edited this page Jul 16, 2024
·
364 revisions
The metagen module automatically places relevant metadata at the top of your .norg
files.
The metagen module exposes two commands - :Neorg inject-metadata
and :Neorg update-metadata
.
- The
inject-metadata
command will remove any existing metadata and overwrite it with fresh information. - The
update-metadata
preserves existing info, updating things like theupdated
fields (when the file was last edited) as well as a few other non-destructive fields.
-
(boolean)
Whether or not to call
:h :undojoin
just before changing the timestamp inupdate_metadata
. This will make your undo key undo the last change before writing the file in addition to the timestamp change. This will move your cursor to the top of the file. For users with an autosave plugin, this option must be paired with keybinds for undo/redo to avoid problems with undo tree branching:vim.keymap.set("n", "u", function() require("neorg.modules").get_module("core.esupports.metagen").skip_next_update() local k = vim.api.nvim_replace_termcodes("u<c-o>", true, false, true) vim.api.nvim_feedkeys(k, 'n', false) end) vim.keymap.set("n", "<C-r>", function() require("neorg.modules").get_module("core.esupports.metagen").skip_next_update() local k = vim.api.nvim_replace_termcodes("<c-r><c-o>", true, false, true) vim.api.nvim_feedkeys(k, 'n', false) end)
false
-
core.autocommands
- Handles the creation and management of Neovim's autocommands. -
core.integrations.treesitter
- A module designed to integrate Treesitter into Neorg.
core.autocommands
core.clipboard
core.clipboard.code-blocks
core.completion
core.concealer
core.defaults
core.dirman
core.dirman.utils
core.esupports.hop
core.esupports.indent
core.esupports.metagen
core.export
core.export.markdown
core.fs
core.highlights
core.integrations.coq_nvim
core.integrations.nvim-cmp
core.integrations.nvim-compe
core.integrations.treesitter
core.itero
core.journal
core.keybinds
core.latex.renderer
core.looking-glass
core.neorgcmd
core.neorgcmd.commands.return
core.pivot
core.presenter
core.promo
core.qol.toc
core.qol.todo_items
core.queries.native
core.scanner
core.storage
core.summary
core.syntax
core.tangle
core.tempus
core.text-objects
core.todo-introspector
core.ui
core.ui.calendar