Releasing from Source Control

When you're ready to release a beta or release version of the package for your application, you will transfer the source code from Source Control into your packaging org. Thankfully, this can also be achieved with the help of the following Ant script target. Note that unlike the deploy Ant target, this does not attempt to clean the target org!

<target name="deploy.package">
  <sf:deploy 
      username="${sf.username}" 
      password="${sf.password}" 
      serverurl="${sf.server}"
      runAllTests="true"
      deployRoot="${basedir}/src"/>
</target>

The process of updating the packaging org can only be partially automated by running the preceding Ant target, as you still need to log in to the packaging org to add brand new components that are not automatically added through a relationship with components already in the package.

The following is a list of recommended steps to update and confirm that the content of your packaging org matches the content of Source Control:

  1. Run the following command (all on one command line):
    ant deploy.package 
    -Dsf.username=packagingusername 
    -Dsf.password=packagingpasswordpackagingtoken
    
  2. Log in to the packaging org and review the contents of the package. You can utilize the Add Component page to determine whether components now reside in the packaging org that are not presently included in the package.
  3. Rename the /src folder to /src.fromsc and create a new /src folder. Then, run the retrieve.package Ant target as per the command line you used to download files from the packaging org at the beginning of this chapter.
  4. Compare the /src and /src.fromsc folders using your favorite file comparison tool. Review differences to determine whether changes exist either in the packaging org or in the Source Control system that do not belong to the application being packaged!
  5. As per best practice, confirm that your package dependencies are still as expected. Then, perform an upload in the usual way as discussed in the previous chapters.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.222.182.66