enhance(main/usbmuxd): Add helper script to imitate persistent daemon#29146
Closed
alexytomi wants to merge 2 commits into
Closed
enhance(main/usbmuxd): Add helper script to imitate persistent daemon#29146alexytomi wants to merge 2 commits into
alexytomi wants to merge 2 commits into
Conversation
Note: By iDevice, this means iPhones, iPads, iPods, Airpods, etc. Apple Products if you will. This script restarts usbmuxd to refresh the fd provided by `termux-usb` when iDevice is disconnected, imitating how it normally behaves on traditional desktop linux. This is intended to be ran by any program that will use usbmuxd. We cannot have multiple iDevices connected due to `termux-usb` limitations so the best we can do is warn the user about it. If there are multiple USB devices connected, the script will cycle each one of them and ask the user for permission before verifying whether the device is an iDevice.
…`libimobiledevice` This is the correct dependency to actually run `usbmuxd`, even moreso for the helper script
Contributor
Author
|
This is a very janky workaround. What would be better is to wait for termux/termux-api-package#204 and patch |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changes
Why
Users have to figure out how to use the janky workaround of manually using termux-usb. This script stops that madness and tries to imitate how it work on desktop, while running it will try to connect to an Apple device using the termux-usb workaround and maintain that connection.
Downsides
Sadly this doesn't really do the daemon part of usbmuxd as there's no way to get a notification if a USB device was plugged, that means we would have to continuously poll Termux:API if we wanted this to run as a service/daemon type of thing which causes issues on some ROMs that don't like spamming
termux-usbcommands although if that is preferred I would be happy to rewrite everything as a runit service that just polls.