We have enabled Dev Hub in our org but we are not using Salesforce DX. Since Dev Hub is enabled, when we create projects, we get SFDX folder structure. But when we do code merge, our code repository is in Non-Salesforce DX structure and need help in figuring out how to get Non-Salesforce DX structure

  • Can you add some detail on what operations you are doing? Are you running sfdx:project:init, or pulling metadata from scratch orgs? – David Reed Jun 5 at 20:28
  • That doesn't sound right. If you're using sfdx to create a project, you'll get sfdx. If you use a regular IDE (say, IntelliJ) then you can simply retrieve the metadata regularly. – Sebastian Kessel Jun 5 at 20:30
  • 1
    You can use the force:mdapi:deploy and force:mdapi:retrieve commands to pull/push metadata in the old format, but there's no GUI for it, since VS Code is meant primarily to assist with developing in DX format. – sfdcfox Jun 5 at 20:36
  • 1
    If you are using VS Code with the official Salesforce extensions then you are using sfdx. It has little to do with whether you've enabled DevHub or not. The Salesforce extensions for VS code only work with the sfdx project folder structure. You need to either convert your source to/from Metadata API format, into your source control (which seems dicey), or perhaps use a different extension like ForceCode that works with the MDAPI/package.xml folder structure. – Thomas Taylor Jun 5 at 21:03
  • @sfdcfox your comment solved my problem. can you post your comment as an answer so that i can accept it. – Suneel Jun 10 at 20:50

Salesforce DX includes two commands for working with the older Metadata API format: force:mdapi:retrieve and force:mdapi:deploy. You can use these two commands together to work with an existing repository in the old format. These commands don't have a GUI option in VS Code and the official Salesforce DX bundle, but are readily accessible from a terminal window.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.