Code Studio

Development workflow with Code Studio

This section will guide you through the full process of:

Code Studio facilitates the application review in a temporary environment (CDE).

The following instructions provide the possible development flow for a feature called feature-1:

Planning changes to the code

  1. Click Plan > Issues to navigate to the intended project.

  2. Click New issue.

  3. Assign the issue to yourself or a team member with Code Studio access.

  4. Click Create merge request directly from the issue ticket.

Making a change to the code

  1. Navigate to your project in Code Studio (GitLab)

  2. Click the (+) button dropdown to add a new branch.

  3. Enter an appropriate name for the branch. For example, feature-1.

  4. Create the branch.

  5. Add relevant changes to the new branch. For example, add a new file to the feature-1 branch.

Note

Acquia recommends you to ensure that all branches are pushed to and pulled from the shared project repository. Ensure that you do not fork the repository.

Creating a merge request to propose a new change

  1. Click Code > Merge requests > New merge request.

  2. Select the Source branch as feature-1 and the Target branch as the primary branch.

  3. Click Compare branches and continue.

  4. Fill in the necessary details, and then click Create merge request.

Code Studio auto-triggers a new CI pipeline for the merge request. The pipeline status is displayed on the current merge request page. The status might take a minute to update.

Running an automated test against the proposed change

  1. Check the pipeline status on the current merge request page, and select Pipeline status to get more details about the pipeline.

    Note

    The pipeline shows extra CDE create and CDE delete jobs under the deploy stage.

  2. Let the corresponding Code Studio CI pipeline succeed. This might take a few minutes.

Reviewing the proposed change in a CDE

  1. Log in to Cloud Platform and navigate to the respective application.

  2. On the Overview page, find the extra CDE. This CDE is ready to use.

Merging the proposed change

  1. Click Merge to merge the request.

  2. After the merge request is closed, the Delete CDE job from the old pipeline that created the CDE deletes the CDE environment.

  3. If any other environment, like Dev, needs to point to the feature-1 branch, make a code switch.