I have implemented deployment pipeline in Jenkins using SFDX CLI and GitHub.
I am able to deploy metadata to Salesforce Org using below commands.
First, validate the deployment
sfdx force:mdapi:deploy -u ${USERNAME} -c -d src -w 10 --soapdeploy
If validation is successful, below step will be executed.
sfdx force:mdapi:deploy -u ${USERNAME} -d src -w 10 --soapdeploy
My query is whether salesforce deployment using metadata is incremental or not ?
For example, if in first deployment my metadata has class A and in second instance of deployment has Class A and Class B then will second deployment will re-deploy class A or it will only deploy Class B ?
Or whether I need to use some other options like git diff to identify changes and then generate metadata to delpoy ?