junegunn / vim-easy-align

:sunflower: A Vim alignment plugin
4.11k stars 118 forks source link

Map last executed "visual mode" align to a key or to a command #144

Open borisbrodski opened 4 years ago

borisbrodski commented 4 years ago

I would like to repeat last align (that was configured interactively) at some point in the future.

After finishing easy-align interactive mode the plugin prints the resulted command and execute it. This is very nice. But I couldn't find a way to copy this resulted command and reissue it or map it to a key stroke.

If there is currently no way of copying last issued align command, consider this a feature request.

Thank you for amazing plugin. Just love it!

strboul commented 3 years ago

I suppose you have to install a separate plugin for this. See the docs :h <Plug>(EasyAlign)

Notice that the commands are repeatable with . key if you have installed {repeat.vim}{3}. Install {visualrepeat}{4} as well if you want to repeat in visual mode.

{3} https://github.com/tpope/vim-repeat {4} https://github.com/vim-scripts/visualrepeat

borisbrodski commented 3 years ago

Thank you very much for your response. I can repeat the Align with the dot (.), no problem here. What I rather mean is to repeat visually configured align at some point in the future.

Let me rephrase my question/feature request: