User Stories - Git Metadata

Updated 4 months ago by Copado Solutions

If you are upgrading from a previous version, make sure that you have set the Field Level Security and Object Level Security for your profiles and permission sets.

Copado integrates with Git in many ways. From a user story, you will be able to select multiple commits and relate them to it. By clicking on Add Commits, you will be able to select one or more commits which then will be displayed under User Story Commits.

Another way of adding commits to a user story would be using the Commit Files button, which will prompt you to select one or more files from the Salesforce org where the development is being done and a Commit Message. This will automatically retrieve the metadata, create a new commit in the Git repository, and finally create the user story commit automatically. Copado will need  to know the Org - Repository - Branch to orchestrate the integration, you only need to create a Git Snapshot record which will relate these 3 items  (one-time process). Copado will automatically find the Git Snapshot record based on the org where the user story is sitting, and if more than one is found, Copado will ask you to choose one.

When using the promotion process, Copado will combine the metadata (typically configuration) and Git metadata (typically code) to produce one single deployment record which will contain multiple steps. See the Promotion Overview article for more information.

If Add Commits or Commit Files or User Story Commits related list are not displayed on the user story, please edit the user story layout.

Feature Branches

When using CCM and CBM, aka the Copado Git flow, Copado will create feature branches for each user story automatically when using the Commit Files button in the User Story record.

The branch will be called feature/{user-story-number} and it will be created out of the main branch of the pipeline, typically 'master'. The selected files will be committed to the feature branch and then merged into the org's branch, based on the org where the user story is being developed and the branch assigned to that org in the pipeline. The result is an isolated feature branch that has only the changes of the user story, and an org branch which is in sync with the org's metadata.

Retrieve Only

With the Retrieve Only checkbox you will be able to pull OLS/FLS for profiles and permission sets, without having to commit/deploy the original fields or objects.

This feature gives you a more granular control over profiles and permission sets in regard to objects and fields permissions.

How to Use It
  1. Navigate to a Git snapshot or a user story.
  2. Click on Commit Changes.
  3. Notice the new Retrieve Only checkbox. Select this checkbox for the objects you want to pull OLS, but avoid its deployment.


How did we do?