Get path to iOS application based on name or bundle identifier
Is there an easier way to get the path to an iOS application, than searching
I know both the name and the bundle identifier, however the path is not consistent on different iOS devices.
This is for use in a jailbreak tweak, so I can use PrivateFrameworks and other code not allowed by Apple.
- strtoul() Function- Swift
- Hide device Volume HUD view while adjusitng volume with MPVolumeView slider
- Clarification on Apple's Block Docs?
- View Controller being sent a message even though it has been deallocated
- Updating UIAlertView Message dynamically and newline character issue
- Capturing data from Alamofire
3 Solutions Collect From Internet About “Get path to iOS application based on name or bundle identifier”
If you’re running code that executes in Springboard, this should be fairly simple. Get
sharedInstance, then get the
SBApplication you’re looking for with the
applicationWithDisplayIdentifier: method (or using whatever method you choose). The
SBApplication class contains properties for
bundle (among many others), one of which should be what you’re looking for. I haven’t tried this myself, so I can’t guarantee it’ll work, but based on a quick glance at the Springboard header files (you can take a look here, or dump the header files yourself), it should work.
On the other hand, if you’re not running from Springboard (ie. if you’re making an actual App Store-style application), then you may be out of luck. You could look into inter-process communication with Springboard and see if something can be done there, but it’d probably be more trouble than it’s worth.
If running in an app, you can define:
extern NSString* SBSCopyBundlePathForDisplayIdentifier(NSString* bundleId);
and link to the
Or you can use the library AppList and then it’s:
ALApplicationList *al = [ALApplicationList sharedApplicationList]; NSString *appPath = [al valueForKey:@"path" forDisplayIdentifier:bundleID];
In this case it’s doing what Andrew R. mentions in his answer for you. (I assume the same requirements are necessary, i.e. must be running from Springboard.)
- Return from Child View Controller to Container
- Anonymous class in swift
- Xcode 6 Git No Remotes Available
- How to get the list of all video files in iPhone
- iOS “the new iPad” UIDeviceHardware hw.machine codename
- Generics type constraint vs inheritance
- Xcode 6.0.1, Swift, UIKit, CoreGraphics missing
- Real-time data push from server to iOS device WITHOUT APNS
- PBEWithMD5AndDES Encryption in iOS
- Getting PCM data of HLS from AVPlayer
- Memory Warning UIImagepickerController IOS 7
- Unwrapping Swift optional without variable reassignment
- Save image from Camera using Opencv Example
- iOS 6 streaming player com.apple.coremedia.networkbuffering bug
- How to update data on server db through json api?