Skip to content

Commit f634ba3

Browse files
Merge pull request #237 from tkirby/master
Find plist and mobileprovision in unique temp directory
2 parents 6050e7f + e2dda45 commit f634ba3

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

AppBox/Common/UploadManager/UploadManager.m

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ -(void)uploadIPAFile:(NSURL *)ipaFileURL{
4747
[ABLog log:@"Preparing to Upload IPA - %@", ipaFileURL];
4848
NSString *ipaPath = [ipaFileURL.resourceSpecifier stringByRemovingPercentEncoding];
4949
if ([[NSFileManager defaultManager] fileExistsAtPath:ipaPath]) {
50-
[ABLog log:@"nUploading IPA - %@", ipaPath];
50+
[ABLog log:@"Uploading IPA - %@", ipaPath];
5151
//Unzip ipa
5252
__block NSString *payloadEntry;
5353
__block NSString *infoPlistPath;
@@ -85,7 +85,7 @@ -(void)uploadIPAFile:(NSURL *)ipaFileURL{
8585
NSString *mobileProvisionPath = [payloadEntry stringByAppendingPathComponent:@"embedded.mobileprovision"].lowercaseString;
8686
if ([entry.lowercaseString isEqualToString:mobileProvisionPath]){
8787
[ABLog log:@"Found mobileprovision at path = %@",mobileProvisionPath];
88-
mobileProvisionPath = [NSTemporaryDirectory() stringByAppendingPathComponent: mobileProvisionPath];
88+
mobileProvisionPath = [tempDir stringByAppendingPathComponent: mobileProvisionPath];
8989
self.project.mobileProvision = [[MobileProvision alloc] initWithPath:mobileProvisionPath];
9090
}
9191
}
@@ -110,11 +110,11 @@ -(void)uploadIPAFile:(NSURL *)ipaFileURL{
110110

111111
//get info.plist
112112
[ABLog log:@"Final Info.plist path = %@",infoPlistPath];
113-
[self.project setIpaInfoPlist: [NSDictionary dictionaryWithContentsOfFile:[NSTemporaryDirectory() stringByAppendingPathComponent:infoPlistPath]]];
113+
[self.project setIpaInfoPlist: [NSDictionary dictionaryWithContentsOfFile:[tempDir stringByAppendingPathComponent:infoPlistPath]]];
114114

115115
//show error if info.plist is nil or invalid
116116
if (![self.project isValidProjectInfoPlist]) {
117-
NSString *log = @"AppBox can't able to find Info.plist in you IPA.";
117+
NSString *log = @"AppBox was not able to find Info.plist in your IPA.";
118118
if (self.ciRepoProject) {
119119
[[AppDelegate appDelegate] addSessionLog:log];
120120
exit(abExitCodeInfoPlistNotFound);
@@ -154,7 +154,7 @@ -(void)uploadIPAFile:(NSURL *)ipaFileURL{
154154
if (self.ciRepoProject) {
155155
exit(abExitCodeIPAFileNotFound);
156156
} else {
157-
[Common showAlertWithTitle:@"IPA File Missing" andMessage:[NSString stringWithFormat:@"AppBox can't able to find ipa file at %@.",ipaFileURL.absoluteString]];
157+
[Common showAlertWithTitle:@"IPA File Missing" andMessage:[NSString stringWithFormat:@"AppBox was not able to find IPA file at %@.",ipaFileURL.absoluteString]];
158158
}
159159
self.errorBlock(nil, YES);
160160
}

0 commit comments

Comments
 (0)