function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Adam LewisAdam Lewis 

Packaging Org Changes in git (or any VC)

I'm using version control in a multi developer setup, where each developer has their own dev org (and corresponding working copy from Version Control), and there is a common packaging org which acts as the integration environment.  Throughout the course of creating the managed package, the packaging org can make changes to the underlying metadata, which then get picked up by git as changes in the working copy (for the packaging org).  In my desire for my version control system to reflect the state of the metadata as it was actually depoloyed, I commit the changes back and create a tag.

For example:
- A "<deprecated>false</deprecated>" flag is added to all custom fields
- <packageVersions> get modified in .page-meta.xml
- "consumerKey” on packaged connectedApps changes

The devs now pull in the changes from the packaging org to local working copy which tries to sync with their dev org.  Dev org disagrees with these changes and writes back metadata.  In a desire to have VC track my packaging org, now with every commit devs must review all the permanantly dirty metadata files for other changes which need to be staged; this makes commits very error prone and tedious.  If VC tracked the consensus "dev" copy rather than "packaging" view of the world, then I face the same problem of human error, this time as part of the packaging process instead of the dev process.

File ignore patters won't help, since all these changes are in files which need to be tracked.

How to get dev and packaging orgs to stop fighting over my version control?