diff --git a/local/bin/delegator b/local/bin/delegator index 31ae985..3ac08dc 100755 --- a/local/bin/delegator +++ b/local/bin/delegator @@ -33,6 +33,7 @@ curl clipmenu yubikey emoji +spotify-title HERE )" @@ -85,4 +86,7 @@ case "$choice" in choice="$(uni emoji all -f '%(name), %(cldr_full), %(emoji)' | awk -F', ' '{ i=1; while($i != $NF && $i != "") { print($i, $NF); i++ }}' | pick)" inject "${choice##* }" ;; +'spotify-title') + inject "$(curl -L "$(xclip -o)" | sed -n 's@.*\(.*\) - song by \(.*\) | Spotify.*@\1 - \2@p')" + ;; esac