Created
August 10, 2023 14:00
-
-
Save osvein/bcc1b8d1ac5a726535c283ec9731f9a9 to your computer and use it in GitHub Desktop.
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
#include <CoreFoundation/CoreFoundation.h> | |
#include <stdio.h> | |
#ifndef SPRINGBOARDSERVICES_H_ | |
extern NSString* SBSCopyBundlePathForDisplayIdentifier(NSString* bundleId); | |
#endif | |
int main(int argc, char *argv[], char ) | |
{ | |
if (argc < 2) | |
{ | |
fprintf(stderr, "Usage: %s <bundle 1> [bundle 2] .. [bundle n]", argv[0]); | |
return 1; | |
} | |
for (int i = 1; i < argc; i++) | |
{ | |
NSString *path = SBSCopyBundlePathForDisplayIdentifier([NSString stringWithUTF8String:argv[i]]); | |
fprintf(stdout, [path UTF8String]); | |
} | |
return 0; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment