marks.nvim
marks.nvim copied to clipboard
feat: add toggle_mark
Add toggle_mark
command to toggle inputed mark at current line like what kshenoy/vim-signature
(it uses g:SignatureMap.Leader
to toggle inputed mark) does.
Can you please describe really quickly the intended usecase for this; ie, what would this allow that a regular toggle could not? Thanks for the PR.
Can you please describe really quickly the intended usecase for this; ie, what would this allow that a regular toggle could not? Thanks for the PR.
Sure.
This PR add the toggle_mark
, which means the toggle command need a inputed mark to perform its functionality.
Under the setup with require('marks').setup{mappings = { toggle_mark = 'm'}}
as an example:
When press 'ma':
- If there is no mark
a
on current line, it will add a marka
on the current cursor position. - If there is a mark
a
on current line, it will remove the marka
.
@chentoast Would it be possible to merge this?
This would be great to have! Makes total sense, specially after having used this feature with kshenoy/vim-signature
.