Initial import.
commit
7ba5a04a61
@ -0,0 +1 @@
|
||||
subsonic-cli.cfg
|
@ -0,0 +1,22 @@
|
||||
## Installation
|
||||
|
||||
* `pacman -S mpv`
|
||||
* `pip install --user subsonic-cli`
|
||||
* `git clone` this repository.
|
||||
|
||||
## Configuration
|
||||
|
||||
Make a `subsonic-cli.cfg` file in the repository directory with the following
|
||||
contents, customized to your Subsonic/Navidrome server and user.
|
||||
|
||||
```
|
||||
[subsonic-cli]
|
||||
url = https://airsonic.yourdomain.com
|
||||
username = YOUR_USER
|
||||
password = YOUR_PASSWORD
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
* `./play-by-number`
|
||||
* Press a number key to play a song or internet radio.
|
@ -0,0 +1,18 @@
|
||||
#!/bin/bash
|
||||
|
||||
set -e
|
||||
|
||||
while [ true ] ; do
|
||||
read -s -n 1 key
|
||||
|
||||
if [[ ! -z "$last_command" ]]; then
|
||||
kill -9 "$last_command"
|
||||
fi
|
||||
|
||||
case $key in
|
||||
1) mpv --no-video https://somafm.com/poptron.pls & ;;
|
||||
2) subsonic-cli -c subsonic-cli.cfg stream -p id 05713e32cedff5e9a476b37378d1bd50 | mpv --no-video - & ;;
|
||||
esac
|
||||
|
||||
last_command=$!
|
||||
done
|
Loading…
Reference in New Issue