Created
October 25, 2022 21:51
-
-
Save mnlwldr/91cd0b0586abf405fa8aa0fa71aa6f1d to your computer and use it in GitHub Desktop.
bash aliases for playing somafm stations
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
_somafm() { | |
mpv $1 2> /dev/null | awk '/title/ { s = ""; for (i = 2; i <= NF; i++) s = s $i " "; cmd="(date +'%H:%M:%S')"; cmd | getline d; print d,"|",s; close(cmd) }' | |
} | |
alias groovesalad='_somafm "http://ice1.somafm.com/groovesalad-128-aac"' | |
alias defcon='_somafm "http://ice1.somafm.com/defcon-128-aac"' | |
alias deepspaceone='_somafm "http://ice1.somafm.com/deepspaceone-128-aac"' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment