O'Reilly logo

Mastering Application Development with Force.com by Kevin J. Poorman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Choosing metadata

While the build.xml and build.properties files are relatively static, the package.xml file has the possibility of changing every time you make a deploy. At it's simplest, the package.xml file can be as bare bones as this:

<?xml version="1.0" encoding="UTF-8"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
  <types>
    <name>ApexClass</name>
    <members>*</members>
  </types>
  <types>
   <name>ApexPage</name>
    <members>*</members>
  </types>
  <version>31.0</version>
</Package>

This package.xml file specifies two metadata types: ApexClass and ApexPage. And,it directs the Ant migration tool to include all metadata of these two types in the deployment. Essentially, this package.xml affects all classes and pages. Note the package node's ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required