From: Jay Freeman (saurik) Date: Fri, 30 Jul 2010 10:47:15 +0000 (+0000) Subject: Fix new icon cache support. X-Git-Tag: v1.0.3231~2 X-Git-Url: https://git.saurik.com/uikittools.git/commitdiff_plain/916744716282b757f299a1c0c3bc97d6239e5924?ds=sidebyside Fix new icon cache support. --- diff --git a/control b/control index 029866b..a91f06c 100644 --- a/control +++ b/control @@ -9,3 +9,4 @@ Description: UIKit/GraphicsServices command line access Name: UIKit Tools Author: Jay Freeman (saurik) Depiction: http://cydia.saurik.com/info/uikittools/ +Depends: coreutils-bin diff --git a/uicache.mm b/uicache.mm index cf88535..8e69009 100644 --- a/uicache.mm +++ b/uicache.mm @@ -85,16 +85,16 @@ int main() { fprintf(stderr, "%s\n", error == nil ? strerror(errno) : [[error localizedDescription] UTF8String]); } else fprintf(stderr, "cannot open cache file. incorrect user?\n"); - unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-icons"] UTF8String]); - unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-icons.plist"] UTF8String]); + unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-icons", home] UTF8String]); + unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-icons.plist", home] UTF8String]); - unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-smallicons"] UTF8String]); - unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-smallicons.plist"] UTF8String]); + unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-smallicons", home] UTF8String]); + unlink([[NSString stringWithFormat:@"%@/Library/Caches/com.apple.springboard-imagecache-smallicons.plist", home] UTF8String]); - system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/SpringBoardIconCache"] UTF8String]); - system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/SpringBoardIconCache-small"] UTF8String]); + system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/SpringBoardIconCache", home] UTF8String]); + system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/SpringBoardIconCache-small", home] UTF8String]); - system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/com.apple.IconsCache"] UTF8String]); + system([[NSString stringWithFormat:@"rm -rf %@/Library/Caches/com.apple.IconsCache", home] UTF8String]); notify_post("com.apple.mobile.application_installed");