I'm setting up a git repository for an SFDC project across a team of developers.

I think I should commit all metadata comprising the full org so we can manage changes in addition to the usual classes, components, pages, staticresources, and triggers folders. But somehow I think this might be a bad idea as the size of metadata impedes saves to server in Eclipse, and there's just too much clutter in each dev's workspace.

In a single repository, is it possible to manage all metadata, while ensuring each dev can choose to work a subset of the metadata?

I'm open to hearing best practices as well.

2 Answers 2


It's hard to state a best practice as each implementation comes with its own requirements and ease of work. My own source control setup works heavily with continuous integration and allows for us to also have third party developers/consultants work side by side with our internal developers to ensure everyone stays on the same page. In regards to metadata, you can subscribe to whatever you want, it will just depend on how you are moving that from org to org. Our internal developers work with full copies of their orgs in the IDE (which we use MavensMate and SublimeText) and we have no issues with speed, but some of our external devs use Eclipse and only subscribe to what they are working on. We dont really care though, because what they submit to the repo will be merged with a full copy of metadata at multiple points in our process anyways. so for us, its important to have ALL metadata in the repo because repo changes actually build into a salesforce org using the ANT Migration tool.

I would say that a good start would be to identify what the goal of your project is and what you would like to get out of it. There are plenty of people here who can then steer you in the right direction to accomplish what you are looking for.

I have attached a little diagram showing the development process for what i have setup with my org. Developers all work off their own sandboxes and they commit to a developer sandbox meant entirely for merging code that devs are working on. When the commit is made and pushed, i have a feature which grabs that code and attempts a merge without actually merging(so metadata subscription is irrelevant because they are merging actual files in the repo where they build agent actually pulls from). This sends an automated alert to the submitter with a log of what failed in the commit. Once a commit "merges" successfully, a peer review is created where a team member will approve the merge. Once the merge completes successfully, we queue those changes until the end of the day where we push the entirety of all approved and passed commits to selected developer sandboxes (this does have its exceptions but i wont get into that part now. lol. )

QA pulls "completed tickets" of code from the merge org and performs initial testing. In our ticket management system, they can approve initial QA and we queue that commit to be moved to our User Testing/Final QA/Package Build org automatically based off its status. If the ticket passes User acceptance and package merge, the commits tied to that ticket are bundled with other commits on other tickets and builds the "deployment package". At the end of our sprint, our project manager selects the tested and ready to go issues and we build a deployment package to mark our completions for the sprint. This package is then deployed and tested against our Production Copy org. If all checks out clear, we send the exact same package to production and call it a day. Pretty much everything is automated and easy for every member of the team, and shows absolutely no bias on how a developer chooses to work with code or metadata.

I don't know if any of this is helpful at all, but hopefully it can help show that each org is different, and that the strategy you choose for your source control/continuous integration needs to be one that fits into your business. The single org model without the other, external devs part


I save everything in Git, and solve speed issues by not using eclipse.

At the very least, you could (creatively) utilize git sub-modules to store each metadata type beyond the classes, components, pages, staticresources and trigger folders. That way, dev's don't have to initialize all the submodules, just the one's they're working with.

  • "solve speed issues by not using eclipse" for what? Deployments? Development? Repository commits?
    – Mark Pond
    Oct 31, 2014 at 19:57
  • all of the above. Use mavensmate
    – Kevin P
    Oct 31, 2014 at 20:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .