Newer Version Available
Retrieve Changes to Profiles with Source Tracking
Without source tracking, retrieving profiles only returns some profile information. Retrieving profiles returns information about profiles that pertains to other items specified in the package.xml file.
For example, retrieving profiles with this package.xml file returns profile permissions for the MyCustomField__c custom field on the Account object.
With source tracking, retrieving profiles returns profile information pertaining to anything else specified in the package.xml file plus any components getting tracked by source tracking. That includes any entity for which a change exists between your local project and the org.
For example, say you create a custom field on the Opportunity object called OppCustomField__c in your local environment. Source tracking detects the change and reports it. Now you retrieve profiles using the same package.xml file as you did when source tracking was off.
Even though the package.xml file doesn’t reference OppCustomField__c, because source tracking is tracking the new custom field, your retrieve returns profile permissions for both the MyCustomField__c custom field on the Account object and the OppCustomField__c on the Opportunity object.
For more information about retrieving profiles, see the Profile metadata type in the Metadata API Developer Guide.