I am using fastlane to handle provisioning.
This is what I did:
match nuke development match nuke distribution
then in a lane I have this for each bundleId I need to provision for:
match(type: "development", app_identifier: "com.myCompany.myApp", force_for_new_devices: true)
When I want to download the provisioning I have a lane that does this:
match(type: "development", app_identifier: "com.myCompany.myApp", readonly: true)
All this lets me work and build fine on devices that were ALREADY in the portal at the time of nuke.
How do I update provisioning correctly if I want to add a device?
I tried this:
match development --force_for_new_devices true -a com.myCompany.myApp
It does not work.
I get this error:
Provisioning profile '82afbd5b-9f19-4c78-b3ac-56a3565ce3f2' is not available on the Developer Portal
The only thing that works every time I have to add a device is to nuke everything and start fresh.
What's the proper way to add a device without having to nuke??
I am using Xcode 8, I disabled the automatic provisioning like suggested by fastlane.
Adding a new device to the Ad Hoc ProfileGo to the iOS Provisioning Portal and click on Provisioning. Select the Distribution tab. 2. Select the Ad Hoc profile you want to modify and click 'Edit'.
After logging in to the iOS Provisioning Portal, click Devices in the sidebar. Click Add Devices. Enter a device name and the device ID. Click Submit.
Use the match_nuke action to revoke your certificates and provisioning profiles. Don't worry, apps that are already available in the App Store / TestFlight will still work. Builds distributed via Ad Hoc or Enterprise will be disabled after nuking your account, so you'll have to re-upload a new build.
Since fastlane version 2.8 there is a new way to add a device via the command line
fastlane run register_device udid:"1234…890" name:"My new iPhone"
To refresh e.g. the the developer provision profile to include this device run:
fastlane match development --force
To get the udid(serial number) of a connected phone simply run the command system_profiler SPUSBDataType | grep -A 11 -w "iPad\|iPhone\|iPad"
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With