Automatic generation of `package.xml` based on modified files in a Salesforce project
npm install sf-package-autogenAutomatic generation of package.xml based on modified files in a Salesforce (SFDX) project.
bash
npm install -g sf-package-autogen
`⚙️ How to use
`bash
sf-package-autogen --from origin/main --to HEAD --output ./manifest/package.xml
sf-package-autogen --from master --to HEAD --output ./manifest/package.xml // todo
`
$3
| Argument | Description | Default Value |
|-----------|-----------------------------------------------|-------------------|
|
--from | Branch or commit to start comparing changes from | origin/main |
| --to | Branch or commit to compare changes to | HEAD |
| --output| Path to save the generated package.xml | ./package.xml |🧠 Example
If files have been modified:
`
force-app/main/default/classes/MyClass.cls
force-app/main/default/lwc/myComp/myComp.js
`The generated output will be:
`xml
MyClass
ApexClass
myComp
LightningComponentBundle
64.0
``