ecthelionvi / NeoComposer.nvim

Neovim plugin that simplifies macros, enhancing productivity with harmony.
MIT License
399 stars 9 forks source link

Feature Request - Adding Filetype-Specific Macros and Namespaces #5

Open mthbrown opened 1 year ago

mthbrown commented 1 year ago

Hi,

I really like NeoComposer. It reminds me of a plugin I use in normal Vim named Marvim but which hasn't seen much activity lately.

As they basically serve the same purpose (I still haven't tested Marvim in Neovim), I was wondering if you planned on additional some additional features that it supports that I don't see in NeoComposer such as:

Thanks

ecthelionvi commented 1 year ago

Thank you for the feedback. Can you walk me though what those new features would look like? You mentioned namespace. Does that mean the ability to name your macros? How would you prefer to interact with those features given the current ui? Lots of questions, I know 🥹 Just trying to determine the best way to implement it.

mthbrown commented 1 year ago

Yes. You can name macros. By default, macros are saved in a namespace corresponding to the filetype you had open when you saved the macro. They also pop-up when I invoke it when I have a file of that filetype open. So if I have some macros specific to markdown, it would automatically prepend the markdown namespace to the name of the macro and it would be named: markdown:name_of_macro. When you tell it to run a macro and you are in a markdown file, it would automatically open the markdown namespace and allow you to select one of the named macros. I could backspace and change the namespace to something else if I wanted to (so I can manually create a namespace where I have my generic macros and then tell it to run this)

ecthelionvi commented 1 year ago

Sorry I haven't forgotten. I've just been swamped with school and internship obligations. 😅

raphaklaus commented 7 months ago

I second this. For my use case, being able to name macros for future usage and have them versioned somewhere (for fast setup / sharing) is key. That also allows a small community to grow around this tool as macros now become shareable utilities.

The way I see this design:

Let me know what you think. Perhaps I could try to write something.

ecthelionvi commented 7 months ago

I welcome any PRs, but I don't have the bandwidth right now to make any major changes.