Ingredients:
1. Termux App.
2. Termux API App.
3. Termux CLI utilities. apt install termux-api
4. Python: apt install python
5. youtube-dl: pip install youtube-dl
6. VLC App. Install from app store.
7. A set of shell functions for clipboard and application access:
alias xc='termux-clipboard-set'
alias xp='termux-clipboard-get'
open ()
{
termux-share "$@"
}
I'll generally download videos to the Download folder, which I've symlinked from the Termux home directory: lrwxrwxrwx 1 u0_a204 u0_a204 29 Apr 26 2016 Download -> /storage/emulated/0/Download/
Oh, and how did I get those functions and aliases? (alias | egrep x[cp]; typeset -f open) | sed s/^/ / | xc
(Pre-formatted for HN's code block.)With all of that, you can download and play, in one swell foop, a video (assuming you know the output format you prefer -- something you can set as a youtube-dl preference):
open $( youtube-dl -f 18 "$(xp)" | awk -F':' '/Destination/ {print $2}' )
Or you can fetcha whole slew of content and queue it up on VLC.I'd still prefer to be able to use a commandline audio player with controls rather than the GUI client. There's a very simple "play-audio" command, but it has no controls -- <ctrl>-C to end is about it, even backgrounding doesn't actually stop playback.
I've messed with the sox "play" command, but it doesn't have an assigned audio device, and I've been unable to convince it that such a thing exists (see StackExchange posts regarding Android for similar issues/discussions).