Saturday, April 14, 2018

Developer tips - Visual Studio - plist files

Disclaimer !
This article is based on tests/research/finding at April 2018. Things can change.

A project in Visual Studio that involve Apple iOS has some configurations saved in files ending with the .plist suffix.
These files are Property List files.

These files, combined with the project setting, contribute to set up the application configuration that need to match the content of the Provisioning profile.

However the files "per se" contains only few XML lines.

Property Files

A project usually has two of these files :
  • info.plist
  • Entitlement.plist


This file contains some major important setting for the projects.
Note that for Android some of these settings are embedded in the project configuration rather than an external file.
This mechanism is mainly for Apple iOS.


This file contains settings that need to match the Provisioning profile used.

Property Editor

Xamarin has a Property List editor, a GUI based editor for the .plist files.
The  editor goes to modify actually the plist file directly. i.e the information are actually stored in the plist file, there are no redirection to data base or online resources or other hidden stuff nor the plist is populated based on the certificate or provisioning profile issued.

The reason why turning some options ON or Off and nothing happens in the plist file, is because not all the options are actually supported by the Xamarin Plist editor, especially for the Entitlements.
For example the the Data protection and other choices will not produce any effect on the plist file.

The only option usually needed (for the Entitlement.plist file) working is the Push notification.
Note that for the App store the value of such option should be Production and NOT the default Development ( if you leave Development Apple Store will refuse to accept the app).
And of course in the Plist editor you MUST manually edit such value.
If you play with the option only from the GUI, like removing it and reinstating it, it will have the Development value, not the Production.


No comments:

Post a Comment