Posts

Showing posts with the label Force.com Migration Tool

Get Complete Package.xml

Below are a few interesting post about preparing package.xml automatically. https://github.com/JitendraZaa/AutoGenerate_Package.xml_Ant http://www.tquila.com/blog/2014/02/11/salesforce-packagexml-builder https://packagebuilder.herokuapp.com/ There is no way to figure out wild card metadata components (*) using API. Also, there is no way to figure out what components are not supported as part of force.com migration tool.  Out of above posts, I found Jitendra's post very interesting and useful. Whereas packagebuilder by Tquila guys, generates an exhaustive list of package.xml file for your organization.  On a side note Tquila guys have build a few interesting heroku apps.  https://sfswitch.herokuapp.com/  - To switch components between orgs.  sforgcompare.herokuapp.com    - To compare metadata between orgs. Watch this space for more info!

Salesforce.com migration tool - Deploying Weblink and migrating files with special characters

Image
Recently, I noticed the followed issues in SFDC Ant deployment. Issue 1: Typo in XML <name> metadata data for Web Link Just to reiterate, all the buttons and links created under "Buttons and Links" section of the Object are treated as Web Links . Screenshot from Force.com Migration Tool Guide It should be WebLink, not Weblink. Otherwise, the following error occurs while extracting the package :  package.xml - Entity type: 'Weblink' is unknown. Correct XML is:  <types> <members>Opportunity.Cancel_CheckOut</members> <members>Opportunity.Generate_Deal_Sheet</members> <name>WebLink</name> </types> Issue 2: Unable to deploy entities with special characters Example: <types> <members> User w/Export  </members> <name>Profile</name> </types> I tried to deploy Profile entities with special characters like '-' and '/...

How to package a single workflow using Force.com Migration tool?

Extracting a single workflow out of force.com can be a little tricky. I am using ANT/JAVA migration tool to extract force.com metadata. From the documentation it is clear that 'Workflow' tag should be used to extract workflow. <types><members>*</members><name>Workflow</name></types> The above component in project manifest - package.xml will fetch all the workflows related to Opportunity. How to fetch a specific workflow? dot operator will not work in this case. One way to get around this limitation is specifying the following components related to a workflow as appropriate. WorkflowAlert WorkflowFieldUpdate WorkflowOutboundMessage WorkflowRule WorkflowTask For example, a workflow sends an email and does a field update upon meeting a certain criterion. In package.xml, the following components should be included.  <types> <members>Opportunity.Set_Date</members><name>WorkflowFieldUpdate</name>...