createTabWithDefaultProfileCommand return ni
iTerm2Application *iterm = [SBApplication applicationWithBundleIdentifier:@"com.googlecode.iterm2"];
if (![iterm isRunning]) {
[iterm activate];
}
if ([iterm currentWindow] == nil) {
[iterm createWindowWithDefaultProfileCommand:nil];
}
iTerm2Window *terminal = [iterm currentWindow];
iTerm2Tab *tab = [[terminal currentSession] createTabWithDefaultProfileCommand:nil]; // got nil tab why ???
[tab setCurrentSession:[terminal currentSession]];
[terminal setCurrentTab:tab];