FollieHiyuki-dotfiles/home/.local/bin/lyrics
2021-03-13 18:34:45 +03:00

17 lines
394 B
Bash
Executable File

#!/bin/sh
echo "Artist: " | tr -d '\n'
read -r artist
echo "Song: " | tr -d '\n'
read -r song
# Nice look
echo "========================
"
artist=$(echo "$artist" | sed s/" "/%20/g | sed s/"&"/%26/g | sed s/,/%2C/g | sed s/-/%2D/g)
song=$(echo "$song" | sed s/" "/%20/g | sed s/"&"/%26/g | sed s/,/%2C/g | sed s/-/%2D/g)
curl -s "https://api.lyrics.ovh/v1/$artist/$song" | jq -r ".lyrics"