function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Jon Simmonds 11Jon Simmonds 11 

SFDX script to automate deployments

Has anyone written scripts using SFDX commands to automate deployments?

I am using VS Code and currently manually type the SFDX commands to retrieve and deploy to orgs.

If I wanted to write a script to run multiple SFDX commands together, what type of file would the script be written in and how would you run the script within a VS Code project?
 
VinayVinay (Salesforce Developers) 
Hi Jon,

You can try using copado, gearset tools to automate your deployment.  Also found below references that can help you.

https://www.sfdcstop.com/2019/06/sfdx-deploy-tool.html
https://medium.com/@idanblich/automate-changeset-actions-using-sfdx-salesforce-fbe7bfe4e411

Hope above information was helpful.

Please mark as Best Answer so that it can help others in the future.

Thanks,