0

Shenzhen スクリプトで IPA を生成しようとしています: https://github.com/nomad/shenzhen

ここに私が現在持っているコードがあります:

-(void)startBuildIPAForProject:(NSString*)path
{
    task = [[NSTask alloc] init];
    [task setLaunchPath:@"/bin/bash"];
    [task setCurrentDirectoryPath:path];
    [task setArguments:@[@"ipa build",@"-c",@"Release"]];

    NSPipe *pipe;
    pipe = [NSPipe pipe];
    [task setStandardOutput: pipe];

    NSFileHandle *file;
    file = [pipe fileHandleForReading];

    [task launch];

    NSData *data;
    data = [file readDataToEndOfFile];

    NSString *string;
    string = [[NSString alloc] initWithData: data
                                   encoding: NSUTF8StringEncoding];
    NSLog(@"task output: %@",string);

    [task waitUntilExit];
}

[タスク起動] を実行すると、コンソールから次の出力が得られます。

/bin/bash: ipa build: No such file or directory

通常のターミナルを使用すると、ipaビルドが機能しています(つまり、現在のディレクトリにXcodeプロジェクトが存在しないことがわかります)

私は少し迷っているので、どんな助けも大歓迎です。

4

1 に答える 1