Heredoc and snips
I like to use https://snips.sh to store quick snippets, or my own self-hosted one https://snips.jackstupple.uk which I have the API enabled on (PR is just awaiting merge.)
An issue I come across at times is that I have something in my clipboard which I don't want a random file for, but it is like 10 or so lines long so an echo
just isn't going to cut it. Introducing the wonderful, not very new, heredoc piping to snips.
cat << EOL | ssh snips.sh
Typing that and pressing enter will bring you into the heredoc view, kinda like when you forget to close a quote. Paste your stuff there and then when done you type EOL
and then you will be presented with your snippets URL.
Member discussion