-
-
Notifications
You must be signed in to change notification settings - Fork 4.8k
Description
Feature description
I found a series of commands (a modification of https://gist.github.com/Cyang39/917f59062fc9d57302d94e3fc534fb16 ) intended for Termux, that I can use to download soundtracks from my Steam account, a feature I notice is frequently requested of their app. However, it's pretty involved, and would be nice to wrap in an app. However, it involved several layers of chroot-ing and a (potentially) interactive shell program that takes like 30 seconds to start up (SteamCMD, x86 emulated via FEX-Emu). My vision was to attach an app to a virtual shell, and the app would provide buttons with standard actions (install dependencies, start the session, log in, list albums, etc) that would inject commands into stdin and perform limited parsing of stdout, as well as mirroring output for the user to see in case something goes wrong or it e.g. wants them to log in again or w/e. However, I don't see a way to do that - RUN_COMMAND runs a single command, waits for it to complete, and returns the result. I might be able to write the app to work with standalone scripts, but I think it'll be slower (having to boot the environment on every action) and less fault-recoverable (since the user can't see errors until after the script has shut down). Is there an existing way to get access to an interactive session from a third-party app? Some workaround perhaps, like starting a script that redirects to some sockets, or somethings? I'm not sure what Android's security model permits. (Or, is there a way to initialize a Termux environment in a manually created Process?) If not, how difficult would this be to implement? Say, you send stdin intents with specified session IDs, and every N milliseconds any new stdout/stderr gets sent back.
Additional information
Approximate goal: https://gist.github.com/Cyang39/917f59062fc9d57302d94e3fc534fb16 , and being able to interactively run Termux > FEXDroid (on Ubuntu) > FEXBash > SteamCMD.