Update app-store-connect register-device to accept now accepts multiple UDIDs from a file or an environment variable as a source.
Introduce --ignore-registration-errors flag for app-store-connect register-device to continue registering devices despite errors.
Introduce short flags for app-store-connect register-device:
-n flag for the device name,
-u flag for the UDIDs.
Demonstration of the command and its output
## File content
```
00000000-000000000000001E
00000000-000000000000002E
00000000-000000000000003X
```
UDIDs in file:
1. Valid UDID, but the device is present.
2. Valid UDID, the device doesn't yet exists and will be registered
3. Invalid UDID
## Command
```shell
app-store-connect register-device -n iPhone -u @file:Device\ UDIDs.txt --ignore-registration-errors
```
## Output
```
Creating new Device: udid: 00000000-000000000000001E, name: iPhone, platform: IOS
Failed to register a device: POST https://api.appstoreconnect.apple.com/v1/devices returned 409: There is a problem with the request entity - A device with number '00000000-000000000000001E' already exists on this team.
Creating new Device: udid: 00000000-000000000000002E, name: iPhone, platform: IOS
-- Device (Created) --
Id: H2985X3P8Q
Type: devices
Class: IPOD
Name: iPhone
Platform: IOS
Status: ENABLED
Udid: 00000000-000000000000002E
Created Device H2985X3P8Q
Creating new Device: udid: 00000000-000000000000003X, name: iPhone, platform: IOS
Failed to register a device: POST https://api.appstoreconnect.apple.com/v1/devices returned 409: An attribute in the provided entity has invalid value - An invalid value '00000000-000000000000003X' was provided for the parameter 'udid'.
```
The syntax highlight demonstration
app-store-connect register-device
to accept now accepts multiple UDIDs from a file or an environment variable as a source.--ignore-registration-errors
flag forapp-store-connect register-device
to continue registering devices despite errors.app-store-connect register-device
:-n
flag for the device name,-u
flag for the UDIDs.Demonstration of the command and its output
## File content ``` 00000000-000000000000001E 00000000-000000000000002E 00000000-000000000000003X ``` UDIDs in file: 1. Valid UDID, but the device is present. 2. Valid UDID, the device doesn't yet exists and will be registered 3. Invalid UDID ## Command ```shell app-store-connect register-device -n iPhone -u @file:Device\ UDIDs.txt --ignore-registration-errors ``` ## Output ``` Creating new Device: udid: 00000000-000000000000001E, name: iPhone, platform: IOS Failed to register a device: POST https://api.appstoreconnect.apple.com/v1/devices returned 409: There is a problem with the request entity - A device with number '00000000-000000000000001E' already exists on this team. Creating new Device: udid: 00000000-000000000000002E, name: iPhone, platform: IOS -- Device (Created) -- Id: H2985X3P8Q Type: devices Class: IPOD Name: iPhone Platform: IOS Status: ENABLED Udid: 00000000-000000000000002E Created Device H2985X3P8Q Creating new Device: udid: 00000000-000000000000003X, name: iPhone, platform: IOS Failed to register a device: POST https://api.appstoreconnect.apple.com/v1/devices returned 409: An attribute in the provided entity has invalid value - An invalid value '00000000-000000000000003X' was provided for the parameter 'udid'. ``` The syntax highlight demonstrationPrevious PR for the related functionality.