It did work in my project, then I updated xcode
or something, and now it no longer works – the app hangs on launch.
I tried a completely new project following the quickstart ( http://docs.ionic.io/docs/deploy-quick-start) and I get the same result. I get this in my xcode console:
2016-06-16 13:07:13.609 HelloCordova[91822:1734491] [CDVTimer][TotalPluginStartup] 1.186967ms
2016-06-16 13:07:13.862 HelloCordova[91822:1734491] uuid is:
2016-06-16 13:07:13.863 HelloCordova[91822:1734491] ignore version:
see also: https://github.com/driftyco/ionic-plugin-deploy/issues/70
Ionic Deploy Quick Start
# sign in to your Ionic account, first
ionic start deploy-test tabs
cd deploy-test
ionic add ionic-platform-web-client
ionic io init
ionic config build
ionic platform add ios
ionic plugin add ionic-plugin-deploy
ionic build ios
ionic emulate, OK
add to DashCtrl
file: www/js/controllers.js
.controller('DashCtrl', function($scope) {
var deploy = new Ionic.Deploy();
// Update app code with new release from Ionic Deploy
$scope.doUpdate = function() {
deploy.update().then(function(res) {
console.log('Ionic Deploy: Update Success! ', res);
}, function(err) {
console.log('Ionic Deploy: Update error! ', err);
}, function(prog) {
console.log('Ionic Deploy: Progress... ', prog);
});
};
// Check Ionic Deploy for new code
$scope.checkForUpdates = function() {
console.log('Ionic Deploy: Checking for updates');
deploy.check().then(function(hasUpdate) {
console.log('Ionic Deploy: Update available: ' + hasUpdate);
$scope.hasUpdate = hasUpdate;
}, function(err) {
console.error('Ionic Deploy: Unable to check for updates', err);
});
}
})
add to Dash template
file: www/templates/tab-dash.html
<button class="button button-primary button-block " ng-click="checkForUpdates()">
Check for updates
</button>
<button class="button button-stable button-block button-pulse" ng-if="hasUpdate" ng-click="doUpdate()">
download update
</button>
replace in .plist
file: platforms/ios/HelloCordova/HelloCordova-Info.plist
<key>NSAppTransportSecurity</key>
<dict>
<key>NSExceptionDomains</key>
<dict>
<key>amazonaws.com</key>
<dict>
<key>NSThirdPartyExceptionMinimumTLSVersion</key>
<string>TLSv1.0</string>
<key>NSThirdPartyExceptionRequiresForwardSecrecy</key>
<false/>
<key>NSIncludesSubdomains</key>
<true/>
</dict>
<key>amazonaws.com.cn</key>
<dict>
<key>NSThirdPartyExceptionMinimumTLSVersion</key>
<string>TLSv1.0</string>
<key>NSThirdPartyExceptionRequiresForwardSecrecy</key>
<false/>
<key>NSIncludesSubdomains</key>
<true/>
</dict>
</dict>
<key>NSAllowsArbitraryLoads</key>
<true/>
</dict>