3 ms·
If you bother to compose half a page on a software problem, might as well provide a solution, no? runCb(){ cb; echo -e '\n\nGo on? (y/n)'; read -sn 1 ans; if
by pskocik 11y ago
If you bother to compose half a page on a software problem, might as well provide a solution, no?
runCb(){ cb; echo -e '\n\nGo on? (y/n)'; read -sn 1 ans; if [ "$ans" = y ]; then eval "`cb`"; else true; fi; } #cb should output the contents of your clipboard
Or another option would be to switch your terminal to editing mode (v in the normal mode of `set -o vi`), paste it there, and do `:wq` to run it.