Project: titanium
Issue TIMOB-17716: iOS: Build does not properly error when no distribution certs exist
When building an iOS app for dist-appstore and you do not have any distribution certs, it does not properly error and exit the build. Instead it displays a message if {{ios.distributionName}} is set, otherwise does not display an error. {code} ti build -p ios -T dist-appstore Titanium Command-Line Interface, CLI version 3.5.0-dev, Titanium SDK version 3.5.0 Copyright (c) 2012-2014, Appcelerator, Inc. All Rights Reserved. Please report bugs to http://jira.appcelerator.org/ [ERROR] Invalid distribution certificate "Appcelerator, Inc. (WP4952RUHJ)" {code} The build will continue and eventually die because distributionName is undefined: {code} [INFO] Deploy type: production [INFO] Building for target: dist-appstore [INFO] Building using iOS SDK: 8.0 [INFO] Building for device family: universal [DEBUG] Setting Xcode target to Release [DEBUG] Setting Xcode build OS to iphoneos8.0 [DEBUG] Xcode installation: /Applications/Xcode-6.0.1.app/Contents/Developer [DEBUG] iOS WWDR certificate: installed [DEBUG] Building for the following architectures: armv7 armv7s i386 [ERROR] Failed to run command "build" [ERROR] TypeError: Cannot read property 'cyan' of null at iOSBuilder.loginfo (/Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/iphone/cli/commands/_build.js:1612:85) at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:610:21 at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:249:17 at iterate (/Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:149:13) at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:160:25 at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:251:21 at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:615:34 at iOSBuilder.initialize (/Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/iphone/cli/commands/_build.js:1578:2) at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:610:21 at /Users/chris/Library/Application Support/Titanium/mobilesdk/osx/3.5.0/node_modules/node-appc/node_modules/async/lib/async.js:249:17 {code} In theory the build will not properly error out when you don't have any keychains, you don't have the WWDR cert installed, there are no valid developer certs, there are no valid distribution certs, and no valid development provisioning profiles.
Story points: 5