vim-unstack
vim-unstack copied to clipboard
Idea: UnstackFromCommand
As a tmux user, my workflow for using unstack is usually:
- run a failing build or test (using vim-test)
- copy (either tmux copy mode or piping 1. to xclip)
- :UnstackFromClipboard
It seems like this could be turned into a single command (UnstackFromCommand) that would streamline this.
Do you think this could be useful? I imagine that in many contexts, the trace might be too messy to send the entire output, so I'm not sure.
Thanks for the suggestion! I'm a little worried about false positives or multiple stack traces being an issue, but will leave this ticket open and think it over for a while.
Using vim's :terminal would allow you to highlight the stack trace and trigger unstack via the mapping (default `
In theory, if you can customize vim-test to automatically pipe stdout to xclip, you could probably write a custom command that runs your test then calls UnstackFromClipboard (or in cases where a vim function runs the test and returns stdout, you can do :UnstackFromText(RunTests())), but I'm still thinking if there's a clean way to generalize this to warrant its inclusion to the plugin.