Delete Metadata Deployment

2020-07-23  本文已影响0人  古月的小七

在正常的部署过程中,Metadata是没有办法去批量删除的。首先是Metadata是不支持DML操作的,所以执行脚本也是行不通的。通过workbench,我们可以有一个比较简单的方式可以支持。参考链接:http://carvingintheclouds.blogspot.com/2013/12/deploying-destructive-changes-using.html
简单的整理一下:

  1. Create a package.xml file
  2. Create a destructiveChanges.xml file
  3. Bundle the two files together in a .zip file
  4. Deploy the .zip package using Workbench

The exact steps for deploying using Workbench 29.0.1 are:

  1. Open the migration menu, then click Deploy
  2. Click Browse... and select the .zip package file
  3. Mark the "Rollback On Error" checkbox
  4. Mark the "Single Package" checkbox
  5. Mark the "Run All Tests" checkbox
  6. Click Next
  7. Review the deployment options, then click Deploy

只要维护好你的 destructiveChanges.xml ,通过上面的方式,就可以很简单的把不需要的metadata 删除了。

上一篇 下一篇

猜你喜欢

热点阅读