You can use the newsboat rss reader which is a fork of newsbeuter and mpv player to subscibe to youtube channels and playlists rss feeds, like bsdnow and create a newsboat macro to open the video with mpv player and use w3m as the default browser or firefox as a secondary browser
* install newsboat, mpv and w3m-img
Create the newsboat config and urls files
Next we need to edit the ~/.newsboat/config file and set the default browser and keyboard macro to open mpv or firefox
Add the code below to the ~/.newsboat/config file
keyboard macros
The config code set the rss feeds to auto-reload when you open newsboat
Then we set the default browser to w3m
We create 2 keyboard macros, one to open mpv as the browser to play videos in rss feeds
and another keyboard macro to use firefox as the browser
the keyboard macro for mpv is set to m, and the keyboard macro for firefox is f
you execute the keyboard macro by pressing comma and then the keyboard macro letter
so to open a youtube video from an rss feed you open the post in newboat and then type comma m
to open a post with firefox open the post in newsboat and then type comma f
to open a post with w3m open the post in newsboat and then type o
add the rss feeds to ~/.newsboat/urls
* edit the ~/.newsboat/urls files
Next we will add the rss feed for the bsdnow playlist on youtube
The bsdnow youtube playlist url looks like this
* we need to grab the code after list=
which is:
We then append the playlist code to the the youtube rss feed for playlist
The youtube rss feed for playlists looks like this
So the complete url we add to the ~/.newsboat/urls files looks like this
The youtube rss feed for channels looks like this
to get the channelid you need to go to the channels page on youtube and view source in the browser
then search for channelid and copy the code for the channelid
for example this is my youtube channel
and the channelid is:
so the complete youtube rss feed for my channel would look like this
opening videos with mpv
so to open a youtube video from an rss feed you open the post in newboat and then type comma m
newsbeuter documentation
newsboat is a fork of newbeuter
* install newsboat, mpv and w3m-img
Bash:
sudo pkg install newsboat mpv w3m-img
Create the newsboat config and urls files
Bash:
touch ~/.newsboat/{config,urls}
Next we need to edit the ~/.newsboat/config file and set the default browser and keyboard macro to open mpv or firefox
Bash:
vim ~/.newsboat/config
Add the code below to the ~/.newsboat/config file
Bash:
auto-reload yes
browser "/usr/local/bin/w3m %u"
macro m set browser "/usr/local/bin/mpv %u"; open-in-browser ; set browser "/usr/local/bin/w3m %u"
macro f set browser "/usr/local/bin/firefox %u"; open-in-browser ; set browser "/usr/local/bin/w3m %u"
keyboard macros
The config code set the rss feeds to auto-reload when you open newsboat
Then we set the default browser to w3m
We create 2 keyboard macros, one to open mpv as the browser to play videos in rss feeds
and another keyboard macro to use firefox as the browser
the keyboard macro for mpv is set to m, and the keyboard macro for firefox is f
you execute the keyboard macro by pressing comma and then the keyboard macro letter
so to open a youtube video from an rss feed you open the post in newboat and then type comma m
Bash:
,m
to open a post with firefox open the post in newsboat and then type comma f
Bash:
,f
to open a post with w3m open the post in newsboat and then type o
Bash:
o
add the rss feeds to ~/.newsboat/urls
* edit the ~/.newsboat/urls files
Bash:
vim ~/.newsboat/urls
Next we will add the rss feed for the bsdnow playlist on youtube
The bsdnow youtube playlist url looks like this
HTML:
https://www.youtube.com/playlist?list=PLUW3LUwQvegyqk2Iqi-YD7Do-AyD4W0s1
* we need to grab the code after list=
which is:
HTML:
PLUW3LUwQvegyqk2Iqi-YD7Do-AyD4W0s1
We then append the playlist code to the the youtube rss feed for playlist
The youtube rss feed for playlists looks like this
HTML:
https://www.youtube.com/feeds/videos.xml?playlist_id=
So the complete url we add to the ~/.newsboat/urls files looks like this
Bash:
# bsdnow youtube playlist rss
https://www.youtube.com/feeds/videos.xml?playlist_id=PLUW3LUwQvegyqk2Iqi-YD7Do-AyD4W0s1
The youtube rss feed for channels looks like this
HTML:
https://www.youtube.com/feeds/videos.xml?channel_id=
to get the channelid you need to go to the channels page on youtube and view source in the browser
then search for channelid and copy the code for the channelid
for example this is my youtube channel
HTML:
https://www.youtube.com/user/NapoleonWils0n
and the channelid is:
HTML:
UCriRR_CzOny-akXyk1R-oDQ
so the complete youtube rss feed for my channel would look like this
HTML:
https://www.youtube.com/feeds/videos.xml?channel_id=UCriRR_CzOny-akXyk1R-oDQ
opening videos with mpv
so to open a youtube video from an rss feed you open the post in newboat and then type comma m
Bash:
,m
newsbeuter documentation
newsboat is a fork of newbeuter