Then install youtube-dl as follows:
$ brew install youtube-dl
And download videos as follows: $ youtube-dl "https://www.youtube.com/watch?v=dQw4w9WgXcQ"The browser is such an obviously poor place to stick A/V. Other than, of course, the fact that advertisers slobber over cramming every more crap down some "channel" or other.
Thank god there's a native iOS/Android client.
Meredith L. Patterson has addressed the point of Port 80 (or 443) adequately. For the time being, we're locked into that.
My point is that handing of A/V material to a dedicated AV app is, all else considered, probably optimal. It's the 4th browser replacement mentioned in my "Tabbed Browsing" rant, elsewhere in this thread.
BTW, I'm unable to access /storage/emulated/0, it seems Termux doesnt have permission (and the app doesnt list it in its permissions). Is your phone rooted?
I've just confirmed though that I can create and delete files on /storage/emulated/0/ YMMV, is all I can say.
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:
I'll generally download videos to the Download folder, which I've symlinked from the Termux home directory: Oh, and how did I get those functions and aliases? (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):
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).