by ebg13 · 7y ago · 0 comments
Can't you do that on any other Android phone with terminal software installed?
It's quicker than any of the YouTube downloader apps I've tried!
How it works: in ~/bin there's a termux-url-opener script that handles what you share:
"#!/bin/bash
case "$1" in
*youtu*)
echo "$1 is a YouTube URL,
downloading"
sh ~/shortcuts/dl_yt.sh $1
..."
(dl_yt just calls youtube-dl -x)I love it and am still finding new uses for Termux. I've got neovim and all my dotfiles loaded, so in a pinch I can ssh into my phone to do some work.
youtube-dl -f bestaudio -x --no-progress -o "~/storage/music/YouTube/%(title)s.%(ext)s" "$1"
This generally gives me .opus files, which play OK but my player can't change the tags.
Modern Android has been locking down access to everything that isn't an NDK public API.
Google is like a feudal lord. In exchange for owning you, they'll protect you from everyone weaker than they are. Google doesn't want to break into your office computer as long as they can shovel ads down your throat. And their reputation for security is much higher than a small startup regardless of the startup's competence and intentions. See e.g. Project Zero or Chrome vulnerabilities vs Firefox.
The best part is that I don't really need to trust Purism, I can choose to trust the community instead to whistleblow if Purism breaks the community's trust. Their target demographic is exactly the type that will be watching over their shoulder to make sure nothing fishy is going on.