Fixed: XcodeCapp nib2cib incorrect vs jake release.

This bug is similar to the previous one in that the effect was the same. If XcodeCapp was used to `nib2cib`, the `NSClasses` setting would be ignored.

The reason for this, apart from the previous bug, was that `nib2cib` needs to be run from the project folder in order to find the main `Info.plist` file.

The fix is to change the CWD to the project folder before building.
This commit is contained in:
Alexander Ljungberg
2016-08-10 13:23:01 +01:00
parent f4c11d14e7
commit 3e56c8ed8b
@@ -90,10 +90,15 @@ NSString * const XCCNib2CibDidEndNotification = @"XCCNib2C
}
- (NSDictionary*)_launchTaskWithCommand:(NSString*)aCommand arguments:(NSArray*)arguments
{
return [self _launchTaskWithCommand:aCommand arguments:arguments currentDirectoryPath:nil];
}
- (NSDictionary*)_launchTaskWithCommand:(NSString*)aCommand arguments:(NSArray*)arguments currentDirectoryPath:(NSString *)aDirectory
{
NSLog(@"Running processing task: %@ on file: %@", aCommand, self.sourcePath);
self->task = [self->taskLauncher taskWithCommand:aCommand arguments:arguments];
self->task = [self->taskLauncher taskWithCommand:aCommand arguments:arguments currentDirectoryPath:aDirectory];
[self _updateOperationInformation];
@@ -125,7 +130,7 @@ NSString * const XCCNib2CibDidEndNotification = @"XCCNib2C
[self dispatchNotificationName:XCCNib2CibDidStartNotification];
NSArray *arguments = @[@"--no-colors", self.sourcePath];
NSDictionary *result = [self _launchTaskWithCommand:@"nib2cib" arguments:arguments];
NSDictionary *result = [self _launchTaskWithCommand:@"nib2cib" arguments:arguments currentDirectoryPath:self.cappuccinoProject.projectPath];
int code = [result[@"status"] intValue];
if (code != 0)