From 885e968aa11e0b458e2e874bdb67a19c1e39a1f1 Mon Sep 17 00:00:00 2001 From: CronyAkatsuki Date: Wed, 27 Dec 2023 22:17:09 +0100 Subject: [PATCH] Fix README --- README.md | 20 ++++++++++++++++++-- 1 file changed, 18 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index f6b182c..e0eb042 100644 --- a/README.md +++ b/README.md @@ -4,15 +4,31 @@ Simple neovim plugin adding a few helping keybinding and ways of writting to hel Marksman allows you to follow files with go to definition and a lot of other things, this plugin is just supposed to be a simple addition to help with things marksman doesn't/can't do as an lsp. -## Planned feature +## Planned features -- Promote or demote headers - Helper's for writting list's - Open web links - Maybe table helper ( There are already a lot of great table plugins so I most likelly won't be implementing that, but link to another one ) - Toggle todo items - Probably some telescope functions +## Features + +### Promoting and demoting headers + +This one's is really explanatory, just set a keybinding and you will be able to quckly promote or demote a header with a keybinding. + +To set the keybinding's for only specific filetype we can use the native loading for specific filetypes inside nevim by placing the file in {neovim_conf}/after/ftplugin/markdown.lua. We can use augroups for this but it isn't recommended. + +> $HOME/.config/nvim/after/ftplugin/markdown.lua +```lua +vim.keymap.set("n", "md", "HeaderDemote", { desc = "Demote markdown header" }) + +vim.keymap.set("n", "mp", "HeaderPromote", { desc = "Promote markdown header" }) +``` + +You can also just use something like lazy.nvim and load the plugin only on markdown and have this be set in config. But that will leave this binding on even in a non markdown file tho. + ## Small feature set I plan for this plugin to be very small and only have a small amount of feature's because there are already a lot of really good neovim plugins for writting markdown but some of them are really big and do a lot of stuff you might don't want them to do.