Converts source-formatted files into metadata that you can deploy using Metadata API.
It executes the force:source:convert command.
In addition to the attributes used by every ant-sfdx task, this task uses the following attributes:
Attribute | Command line equivalent | Description | Required |
---|---|---|---|
manifest | -x | The path for the manifest (package.xml) file that specifies the metadata types to convert. | No. |
outputdir | -d | The output directory to store the Metadata API-formatted metadata files in. | No |
packagename | -n | The name of the package to associate with the metadata-formatted files. | No |
rootdir | -r | A directory other than the default package directory that contains the source-formatted files to convert. | No |
sourcepath | -p | The path to the local source file (or directory) to convert. | No |
Specifies the name of a metadata component to convert.
The sourcepath attribute is a path-like structure and can also be set via a nested <sourcepath>
element.
<force-source-convert rootdir="path/to/source" />
<force-source-convert rootdir="path/to/source" outputdir="path/to/outputdir" packagename="My Package" />
<force-source-convert rootdir="path/to/source"> <metadata>Component1</metadata> <metadata>Component2</metadata> </force-source-convert>
<force-source-convert sourcepath="force-app/main/default/objects/Case"> <sourcepath> <pathelement location="force-app/main/default/objects/Contact" /> <dirset dir="force-app/main/default/objects"> <include name="Ac*" /> </dirset> </sourcepath> </force-source-convert>
Version: 0.0.0-master