Advance Git & GitHub for DevOps Engineers: Part-2

Advance Git & GitHub for DevOps Engineers: Part-2

Table of contents

Task - 1

  1. Create a new branch and make some changes to it.

  2. Use git stash to save the changes without committing them.

  3. Switch to a different branch, make some changes and commit them.

  4. Use git stash pop to bring the changes back and apply them on top of the new commits.

Task - 2

  1. In version01.txt of development, the branch add the below lines after “This is the bug fix in development branch” that you added in Day10 and reverted to this commit. visit here↗ for day10 tasks.

  2. Line2>> After bug fixing, this is the new feature with minor alterations

    1. Commit this with the message “ Added feature2.1 in the development branch

    2. Line3>> This is the advancement of previous feature

      1. Commit this with the message “ Added feature2.2 in development branch”

    3. Line4>> Feature 2 is completed and ready for release

      1. Commit this with the message “ Feature2 completed”

    4. All these commits messages should be reflected in the Production branch too which will come out from the Master branch.

Task - 3

  1. In the Production branch Cherry pick Commit “Added feature2.2 in development branch” and added the below lines in it.

  2. The line to be added after Line 3>> This is the advancement of the previous feature.

  3. Line 4>>Added a few more changes to make it more optimized. Commit: Optimized the feature.

  4. Commit: Optimized the feature.