You can create a change request and merge your changes directly in the source control system, which is the first half of the promotion process. You can complete the promotion by deploying all externally merged changes to the pipeline stage’s associated environment within DevOps Center or by using Salesforce CLI.
You can merge your changes in the source control repository or using git on the command line. To use git commands, see the Git documentation.
Merge Types
When you merge your changes directly in the source control repository, you have these merge options. For more information about merge types and how to merge, see the source control repository’s documentation.
- Merge commit (default)—Enables you to see each commit that is included in the set of changes.
- Squash and merge (recommended)—Combines all commits into a single commit. You can look at a single commit to view your changes as a whole rather than sift through multiple commits.
- Rebase and merge (GitHub, don’t use)—DevOps Center can’t properly reflect the changes, which is likely to cause errors when these changes are promoted through the release pipeline.
- Fast forward (Bitbucket, don’t use)—DevOps Center can’t properly reflect the changes, which is likely to cause errors when these changes are promoted through the release pipeline.
Tips for Creating Change Requests and Merging Directly in the Source Control System
- Select the recommended merge option, Squash and Merge.
- Remember that all externally merged changes are deployed to the associated pipeline stage’s environment. If you’re unsure if you want to move a change forward, wait to merge it.
- Whether you perform your development work in an org or use an IDE, such as Salesforce
Extensions for Visual Studio Code, you can create the change (pull) request directly in
the source control repository. When merging work items in the first pipeline stage’s
branch, be sure to select the pipeline stage’s branch as the base branch instead of
main. - If merging changes from one pipeline stage branch to the next branch in the pipeline,
DevOps Center creates the change request for you. View the list of change requests, and
then select the one you want to merge. Example:
[DevOps Center] Merge WI-000004 to UAT. - Never merge a change request with a title that looks like this:
[DO NOT MERGE] For DevOps Center use only - Integration to UAT.