youtube-subscriptions

terminal UI for viewing youtube subscriptions. Especially well suited for Raspberry Pi.

requirements

installing

You can download a self-contained binary from releases page

setup

Download your youtube subscriptions OPML. and save it as the following file: ~/.config/youtube-subscriptions/subscription_manager

usage

press h for help.

configuration

You can optionnaly add a user configuration at

$HOME/.config/youtube-subscriptions/config.json

example:

```json { "videopath": "HOME/.cache/yts/videos", "cachepath": "HOME/.cache/yts/yts.json", "youtubedlformat": "[height <=? 360][ext = mp4]", "videoextension": "mp4", "players": [ ["/usr/bin/mplayer", "-fs"] ], "channelids": [], "mpvmode": true, "mpv_path": "/usr/local/bin/mpv" }

```

| field | description | default value | ------ | ----------- | ------------- | videopath | directory where videos will be stored | /tmp | cachepath | file path where video list will be stored | /tmp/yts.json | players | list of players command for videos in order of priority | | youtubedlformat | see youtube-dl doc | [height <=? 360][ext = mp4] | videoextension | youtube-dl video extension as per format | mp4 | channelids | list of additional channel ids which will be also fetched | [] | mpvmode | try and start mpv to play the youtubee video first | true | mpvpath | path to mpv binary (will be use if mpvmode is true) | /usr/bin/mpv

__HOME will be substituted with the home path.

download mode

You can update the subscriptions and download the last N videos by running. Here with N = 5:

sh $ youtube-subscriptions 5

This is very usefull to download your subscriptions in a cron.

Don't forget to put the path were youtube-dl is installed.

Example crontab:

cron PATH=/home/pi/.local/bin/:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin 50 * * * * /home/pi/youtube-subscriptions 5 > /home/pi/youtube-subscriptions.log 2>&1

cross compiling for raspberry pi

simply run:

sh ./cross-build-raspberry.sh binary will be in target/arm-unknown-linux-gnueabihf/release/youtube-subscriptions