3 ms·
I use a shell wrapper for mpv that takes the URL from the clipboard when no arguments are given: mpv() { if [ $# -eq 0 ]; then env mpv "$(xsel -b)"
by majewsky 8y ago
I use a shell wrapper for mpv that takes the URL from the clipboard when no arguments are given:
mpv() {
if [ $# -eq 0 ]; then
env mpv "$(xsel -b)"
else
env mpv "$@"
fi
}
- Mashimo 8y agoWhat if you have "&& rm -rf /" in your clipboard and forget about it?
- fjarlq 8y ago$ mpv "&& rm -rf /" Playing: && rm -rf / [file] Cannot open file '&& rm -rf /': No such file or directory Failed to open && rm -rf /.
- atomi 8y agoSince the cat's out of the bag. You can also just use a ClipIt action.