4 ms·
Turn it into a function: rip() { curl -G -H 'Accept: text/plain' \ --url https://dontbeevil.rip/search --data-urlencode "q=$@" } Now `
by cudder 5y ago
Turn it into a function:
rip() {
curl -G -H 'Accept: text/plain' \
--url https://dontbeevil.rip/search --data-urlencode "q=$@"
}
Now `rip hello` works.
- harryvederci 5y agoThis only works with 1-word arguments. You can change $@ to $* to fix that. (I'm acting all wise, but I learned that today as well :) )
- pxeger1 5y agoSwitch to Zsh, where there'll be no difference!