Launch GUI app on iOS 5 through the command line (jailbreak)

限于喜欢 提交于 2019-11-29 21:38:19

问题


I believe you used to be able to launch GUI apps on jailbroken iOS devices via the command line (over SSH) by executing a command like this:

launch com.apple.Calculator

but that is not working on my iOS 5 device (launch not found).

I also tried:

launchctl start com.apple.Calculator

but that also gives me an error (no such process).


回答1:


Those launch/launchctl commands didn't work for me either. What did work was to install the command-line utilty open from Cydia and just execute

open com.apple.calculator

Notice the lowercase c in calculator, that was the bundle identifier for my calculator app.

Here's the developer's website for Cydia stuff:

http://kramerapps.com/cydia/

This links to the repo site:

http://moreinfo.thebigboss.org/moreinfo/depiction.php?file=openData

Update: For iOS 6.x, this current version of open doesn't seem to work. See @Nate's answer to another question linked below in the comments.

Update 2: The open package in Cydia has been updated and now works with iOS 6.

Update 3: Here is the source for the package: https://github.com/conradev/Open. If you look at the open.m file, you can see that the function SBSLaunchApplicationWithIdentifier from the SpringBoardServices private framework is what actually opens the app.



来源:https://stackoverflow.com/questions/8759042/launch-gui-app-on-ios-5-through-the-command-line-jailbreak

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!