Summary
No main branch because we want to manage multiple releases at the same time.
For each release milestone planned to be released to consumers or deployed to production, automatically create release/X.X branch.
For each feature XXX issue, do the following
- Automatically create feature/XXX branch.
- Every time, developers push changes from their local machine git repository feature/XXX branch to the code repository feature/XXX branch, automatically create pull request to merge the changes to the corresponding release/X.X branch.
Every time pull request is merged from source branch to target release/X.X branch, do the following automatically
- Create version tag vX.X.X
- Change the tag in relevant code files and update the pull request
- Run CI/CD pipeline.
- Create branch merge/tag_X_X_X_to_release_Y_Y from tag vX.X.X to merge the changes to the next release release/Y.Y branch.
- Create pull request from merge/tag_X_X_X_to_release_Y_Y branch to the next release release/Y.Y branch.
If CI/CD pipeline fails, then do the following automatically
- Create bug XXX issue for each bug identified in the CI/CD pipeline like automated testing bug.
- Create bug/XXX branch from tag vX.X.X
- Every time, developers push changes from their local machine git repository to the code repository bug/XXX branch, automatically create pull request to merge the changes to the corresponding release/X.X branch.
For each production incident, do the following
- Create problem XXX issue
- Automatically create problem/XXX branch.
- Every time, developers push changes from their local machine git repository problem/XXX branch to the code repository problem/XXX branch, automatically create pull request to merge the changes to the corresponding release/X.X branch.
For each pull request, do the following
- Merge the changes from the target release/X.X branch to the source branch using merge commit
- Run Squash and commit from Github which merges the source branch changes on top of the target release/X.X branch so that previous release/X.X branch commits and tags are left intact in the history of release/X.X branch.
Tutorial
Step | Link | Inputs |
---|---|---|
Create branching-demo repository | https://github.com/organizations/devopscodegen/repositories/new (opens in a new tab) | Repository name = branching-demo Description = Branching demo Visibility = Public - Anyone on the internet can see this repository. You choose who can commit. Choose a license : MIT License Click on Create repository button |
Disable Allow merge commits and Allow rebase merging in Pull Requests | https://github.com/devopscodegen/branching-demo/settings (opens in a new tab) | Uncheck Allow merge commits and Allow rebase merging in Pull Requests sectionChange Default commit message of Allow squash merging to Pull Request title |
Create release/0.0 branch from main branch | https://github.com/devopscodegen/branching-demo/branches (opens in a new tab) | Click on New branch button New branch name = release/0.0 Source = main Click on Create new branch button |
Change default branch from main to release/0.0 | https://github.com/devopscodegen/branching-demo/settings (opens in a new tab) | Section = Default Branch Click on Switch to another branch icon buttonSelect release/0.0 in Filter branches dropdownClick on Update buttonClick on I understand, update the default branch. button |
Delete main branch | https://github.com/devopscodegen/branching-demo/branches (opens in a new tab) | Click on Delete icon button to the right of main branch |
Create demo.md in release/0.0 branch with below content | https://github.com/devopscodegen/branching-demo/new/release/0.0 (opens in a new tab) | Name your file = demo.md Click on Commit changes... buttonClick on Commit changes button |
|release|feature/bug/problem|commit|
|---|---|---|
Step | Link | Inputs |
---|---|---|
Add protect release branches ruleset | https://github.com/devopscodegen/branching-demo/settings/rules/new?target=branch (opens in a new tab) | Ruleset Name = protect release branches Enforcement status = Active Add Target -> Include by pattern Branch naming pattern = release/* Click on Add Inclusion pattern buttonCheck Restrict deletions , Require linear history , Require a pull request before merging , Block force pushes in Branch protections in RulesClick on Create button |
Add feature label | https://github.com/devopscodegen/branching-demo/labels (opens in a new tab) | Click on New label buttonLabel name = feature Color = #0E8A16 (green) Click on Create label button |
Add problem label | https://github.com/devopscodegen/branching-demo/labels (opens in a new tab) | Click on New label buttonLabel name = problem Color = #B60205 (red) Click on Create label button |
Remove description and change color to blue of bug label | https://github.com/devopscodegen/branching-demo/labels (opens in a new tab) | Click on Edit button to the right of bug labelRemove Something isn't working from DescriptionChange Color to #1D76DB (blue) Click on Save changes button |
Delete all labels except feature, bug and problem | https://github.com/devopscodegen/branching-demo/labels (opens in a new tab) | Click on Delete button to the right of all labels except feature, bug and problemClick on OK in Are you sure? Deleting a label will remove it from all issues and pull requests. dialog box |
Create release/1.0 milestone | https://github.com/devopscodegen/branching-demo/milestones/new (opens in a new tab) | Title = release/1.0 Click on Create milestone button |
Create release/1.0 branch from release/0.0 branch | https://github.com/devopscodegen/branching-demo/branches (opens in a new tab) | Click on New branch button New branch name = release/1.0 Source = release/0.0 Click on Create new branch button |
Change default branch from release/0.0 to release/1.0 | https://github.com/devopscodegen/branching-demo/settings (opens in a new tab) | Section = Default Branch Click on Switch to another branch icon buttonSelect release/1.0 in Filter branches dropdownClick on Update buttonClick on I understand, update the default branch. button |
Add tag v1.0.0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git tag v1.0.0
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/1.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/1.0 feature 1 Assignees = assign yourself Labels = feature Milestone = release/1.0 Click on Submit new issue button |
Create feature/release_1_0_feature_1 branch from release/1.0 branch for Issue release/1.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/1 (opens in a new tab) | Click on Create a branch link in Development sectionNew branch name = feature/release_1_0_feature_1 Click on Change branch source linkBranch source = release/1.0 Click on Create branch button |
Create issue for release/1.0 feature 2 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/1.0 feature 2 Assignees = assign yourself Labels = feature Milestone = release/1.0 Click on Submit new issue button |
Create feature/release_1_0_feature_2 branch from release/1.0 branch for Issue release/1.0 feature 2 | https://github.com/devopscodegen/branching-demo/issues/2 (opens in a new tab) | Click on Create a branch link in Development sectionNew branch name = feature/release_1_0_feature_2 Click on Change branch source linkBranch source = release/1.0 Click on Create branch button |
Make changes to feature/release_1_0_feature_1 branch using following commands |
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout feature/release_1_0_feature_1
echo "|1.0|feature1|1|" >> demo.md
git add .
git commit -m "release/1.0 feature 1 commit 1"
echo "|1.0|feature1|2|" >> demo.md
git add .
git commit -m "release/1.0 feature 1 commit 2"
git rebase -i HEAD~2
# Change pick to squash for release/1.0 feature 1 commit 2
# Save the rebase instruction with :wq
# Save the combined commit message with :wq
Step | Link | Inputs |
---|---|---|
Make changes to feature/release_1_0_feature_2 branch using following commands |
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout feature/release_1_0_feature_2
echo "|1.0|feature2|1|" >> demo.md
git add .
git commit -m "release/1.0 feature 2 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from feature/release_1_0_feature_1 branch to release/1.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/1.0...feature/release_1_0_feature_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/1.0 feature 1 commits 1 and 2 to release/1.0 Assignees = Assign yourself Milestone = release/1.0 Click on Create pull request button |
Create pull request from feature/release_1_0_feature_2 branch to release/1.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/1.0...feature/release_1_0_feature_2 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/1.0 feature 2 commit 1 to release/1.0 Assignees = Assign yourself Milestone = release/1.0 Click on Create pull request button |
Merge Pull Request release/1.0 feature 1 commits 1 and 2 to release/1.0 | https://github.com/devopscodegen/branching-demo/pull/3 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v1.0.1 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git tag v1.0.1
git push --tags
Step | Link | Inputs |
---|---|---|
Merge release/1.0 branch changes to feature/release_1_0_feature_2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git checkout feature/release_1_0_feature_2
git merge release/1.0
Step | Link | Inputs |
---|---|---|
Change demo.md file to have following contents |
|release|feature/bug/problem|commit|
|---|---|---|
|1.0|feature1|1|
|1.0|feature1|2|
|1.0|feature2|1|
Step | Link | Inputs |
---|---|---|
Continue the Merge of release/1.0 branch changes to feature/release_1_0_feature_2 using following commands |
git add .
git commit -m "Resolve merge conflict by incorporating both suggestions"
git push -u origin feature/release_1_0_feature_2
Step | Link | Inputs |
---|---|---|
Merge Pull Request release/1.0 feature 2 commit 1 to release/1.0 | https://github.com/devopscodegen/branching-demo/pull/4 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v1.0.2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git tag v1.0.2
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/1.0 bug 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/1.0 bug 1 Assignees = assign yourself Labels = bug Milestone = release/1.0 Click on Submit new issue button |
Create branch bug/release_1_0_bug_1 from tag v1.0.2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch bug/release_1_0_bug_1 v1.0.2
git checkout bug/release_1_0_bug_1
git push --set-upstream origin bug/release_1_0_bug_1
Step | Link | Inputs |
---|---|---|
Link bug/release_1_0_bug_1 branch to issue release/1.0 bug 1 | https://github.com/devopscodegen/branching-demo/issues/5 (opens in a new tab) | Click on gear icon in Development section Select repository devopscodegen/branching-demo Select branch bug/release_1_0_bug_1 Click Apply button |
Create release/2.0 milestone | https://github.com/devopscodegen/branching-demo/milestones/new (opens in a new tab) | Title = release/2.0 Click on Create milestone button |
Create release/2.0 branch from release/1.0 branch | https://github.com/devopscodegen/branching-demo/branches (opens in a new tab) | Click on New branch button New branch name = release/2.0 Source = release/1.0 Click on Create new branch button |
Change default branch from release/1.0 to release/2.0 | https://github.com/devopscodegen/branching-demo/settings (opens in a new tab) | Section = Default Branch Click on Switch to another branch icon buttonSelect release/2.0 in Filter branches dropdownClick on Update buttonClick on I understand, update the default branch. button |
Add tag v2.0.0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git tag v2.0.0
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/2.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/2.0 feature 1 Assignees = assign yourself Labels = feature Milestone = release/2.0 Click on Submit new issue button |
Create feature/release_2_0_feature_1 branch from release/2.0 branch for Issue release/2.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/6 (opens in a new tab) | Click on Create a branch link in Development sectionNew branch name = feature/release_2_0_feature_1 Click on Change branch source linkBranch source = release/2.0 Click on Create branch button |
Make changes to feature/release_2_0_feature_1 branch using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout feature/release_2_0_feature_1
echo "|2.0|feature1|1|" >> demo.md
git add .
git commit -m "release/2.0 feature 1 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from feature/release_2_0_feature_1 branch to release/2.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/2.0...feature/release_2_0_feature_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/2.0 feature 1 commit 1 to release/2.0 Assignees = Assign yourself Milestone = release/2.0 Click on Create pull request button |
Merge Pull Request release/2.0 feature 1 commit 1 to release/2.0 | https://github.com/devopscodegen/branching-demo/pull/7 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v2.0.1 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git tag v2.0.1
git push --tags
Step | Link | Inputs |
---|---|---|
Make changes to bug/release_1_0_bug_1 branch using following commands |
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout bug/release_1_0_bug_1
echo "|1.0|bug1|1|" >> demo.md
git add .
git commit -m "release/1.0 bug 1 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from bug/release_1_0_bug_1 branch to release/1.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/1.0...bug/release_1_0_bug_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/1.0 bug 1 commit 1 to release/1.0 Assignees = Assign yourself Milestone = release/1.0 Click on Create pull request button |
Merge Pull Request release/1.0 bug 1 commit 1 to release/1.0 | https://github.com/devopscodegen/branching-demo/pull/8 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v1.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git tag v1.0.3
git push --tags
Step | Link | Inputs |
---|---|---|
Create branch merge/tag_v_1_0_3_to_release_2_0 from tag v1.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch merge/tag_v_1_0_3_to_release_2_0 v1.0.3
git checkout merge/tag_v_1_0_3_to_release_2_0
git push --set-upstream origin merge/tag_v_1_0_3_to_release_2_0
Step | Link | Inputs |
---|---|---|
Create pull request from merge/tag_v_1_0_3_to_release_2_0 branch to release/2.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/2.0...merge/tag_v_1_0_3_to_release_2_0 (opens in a new tab) | Click on Create pull request buttonAdd a title = Merge tag v1.0.3 to release/2.0 Assignees = Assign yourself Milestone = release/2.0 Click on Create pull request button |
Merge release/2.0 branch changes to merge/tag_v_1_0_3_to_release_2_0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git checkout merge/tag_v_1_0_3_to_release_2_0
git merge release/2.0
Step | Link | Inputs |
---|---|---|
Change demo.md file to have following contents |
|release|feature/bug/problem|commit|
|---|---|---|
|1.0|feature1|1|
|1.0|feature1|2|
|1.0|feature2|1|
|1.0|bug1|1|
|2.0|feature1|1|
Step | Link | Inputs |
---|---|---|
Continue the Merge of release/2.0 branch changes to merge/tag_v_1_0_3_to_release_2_0 using following commands |
git add .
git commit -m "Resolve merge conflict by incorporating both suggestions"
git push -u origin merge/tag_v_1_0_3_to_release_2_0
Step | Link | Inputs |
---|---|---|
Merge Pull Request Merge tag v1.0.3 to release/2.0 | https://github.com/devopscodegen/branching-demo/pull/9 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge buttonClick on Delete branch button |
Add tag v2.0.2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git tag v2.0.2
git push --tags
Step | Link | Inputs |
---|---|---|
Create release/3.0 milestone | https://github.com/devopscodegen/branching-demo/milestones/new (opens in a new tab) | Title = release/3.0 Click on Create milestone button |
Create release/3.0 branch from release/2.0 branch | https://github.com/devopscodegen/branching-demo/branches (opens in a new tab) | Click on New branch button New branch name = release/3.0 Source = release/2.0 Click on Create new branch button |
Change default branch from release/2.0 to release/3.0 | https://github.com/devopscodegen/branching-demo/settings (opens in a new tab) | Section = Default Branch Click on Switch to another branch icon buttonSelect release/3.0 in Filter branches dropdownClick on Update buttonClick on I understand, update the default branch. button |
Add tag v3.0.0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git tag v3.0.0
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/3.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/3.0 feature 1 Assignees = assign yourself Labels = feature Milestone = release/3.0 Click on Submit new issue button |
Create feature/release_3_0_feature_1 branch from release/3.0 branch for Issue release/3.0 feature 1 | https://github.com/devopscodegen/branching-demo/issues/10 (opens in a new tab) | Click on Create a branch link in Development sectionNew branch name = feature/release_3_0_feature_1 Click on Change branch source linkBranch source = release/3.0 Click on Create branch button |
Make changes to feature/release_3_0_feature_1 branch using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout feature/release_3_0_feature_1
echo "|3.0|feature1|1|" >> demo.md
git add .
git commit -m "release/3.0 feature 1 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from feature/release_3_0_feature_1 branch to release/3.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/3.0...feature/release_3_0_feature_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/3.0 feature 1 commit 1 to release/3.0 Assignees = Assign yourself Milestone = release/3.0 Click on Create pull request button |
Merge Pull Request release/3.0 feature 1 commit 1 to release/3.0 | https://github.com/devopscodegen/branching-demo/pull/11 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v3.0.1 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git tag v3.0.1
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/2.0 bug 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/2.0 bug 1 Assignees = assign yourself Labels = bug Milestone = release/2.0 Click on Submit new issue button |
Create branch bug/release_2_0_bug_1 from tag v2.0.2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch bug/release_2_0_bug_1 v2.0.2
git checkout bug/release_2_0_bug_1
git push --set-upstream origin bug/release_2_0_bug_1
Step | Link | Inputs |
---|---|---|
Link bug/release_2_0_bug_1 branch to issue release/2.0 bug 1 | https://github.com/devopscodegen/branching-demo/issues/12 (opens in a new tab) | Click on gear icon in Development section Select repository devopscodegen/branching-demo Select branch bug/release_2_0_bug_1 Click Apply button |
Make changes to bug/release_2_0_bug_1 branch using following commands |
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout bug/release_2_0_bug_1
echo "|2.0|bug1|1|" >> demo.md
git add .
git commit -m "release/2.0 bug 1 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from bug/release_2_0_bug_1 branch to release/2.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/2.0...bug/release_2_0_bug_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/2.0 bug 1 commit 1 to release/2.0 Assignees = Assign yourself Milestone = release/2.0 Click on Create pull request button |
Merge Pull Request release/2.0 bug 1 commit 1 to release/2.0 | https://github.com/devopscodegen/branching-demo/pull/13 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v2.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git tag v2.0.3
git push --tags
Step | Link | Inputs |
---|---|---|
Create issue for release/1.0 problem 1 | https://github.com/devopscodegen/branching-demo/issues/new (opens in a new tab) | Add a title = release/1.0 problem 1 Assignees = assign yourself Labels = problem Milestone = release/1.0 Click on Submit new issue button |
Create branch problem/release_1_0_problem_1 from tag v1.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch problem/release_1_0_problem_1 v1.0.3
git checkout problem/release_1_0_problem_1
git push --set-upstream origin problem/release_1_0_problem_1
Step | Link | Inputs |
---|---|---|
Link problem/release_1_0_problem_1 branch to issue release/1.0 problem 1 | https://github.com/devopscodegen/branching-demo/issues/14 (opens in a new tab) | Click on gear icon in Development section Select repository devopscodegen/branching-demo Select branch problem/release_1_0_problem_1 Click Apply button |
Make changes to problem/release_1_0_problem_1 branch using following commands |
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout problem/release_1_0_problem_1
echo "|1.0|problem1|1|" >> demo.md
git add .
git commit -m "release/1.0 problem 1 commit 1"
git push
Step | Link | Inputs |
---|---|---|
Create pull request from problem/release_1_0_problem_1 branch to release/1.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/1.0...problem/release_1_0_problem_1 (opens in a new tab) | Click on Create pull request buttonAdd a title = release/1.0 problem 1 commit 1 to release/1.0 Assignees = Assign yourself Milestone = release/1.0 Click on Create pull request button |
Merge Pull Request release/1.0 problem 1 commit 1 to release/1.0 | https://github.com/devopscodegen/branching-demo/pull/15 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge button |
Add tag v1.0.4 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/1.0
git tag v1.0.4
git push --tags
Step | Link | Inputs |
---|---|---|
Create branch merge/tag_v_2_0_3_to_release_3_0 from tag v2.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch merge/tag_v_2_0_3_to_release_3_0 v2.0.3
git checkout merge/tag_v_2_0_3_to_release_3_0
git push --set-upstream origin merge/tag_v_2_0_3_to_release_3_0
Step | Link | Inputs |
---|---|---|
Create pull request from merge/tag_v_2_0_3_to_release_3_0 branch to release/3.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/3.0...merge/tag_v_2_0_3_to_release_3_0 (opens in a new tab) | Click on Create pull request buttonAdd a title = Merge tag v2.0.3 to release/3.0 Assignees = Assign yourself Milestone = release/3.0 Click on Create pull request button |
Merge release/3.0 branch changes to merge/tag_v_2_0_3_to_release_3_0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git checkout merge/tag_v_2_0_3_to_release_3_0
git merge release/3.0
Step | Link | Inputs |
---|---|---|
Change demo.md file to have following contents |
|release|feature/bug/problem|commit|
|---|---|---|
|1.0|feature1|1|
|1.0|feature1|2|
|1.0|feature2|1|
|1.0|bug1|1|
|2.0|feature1|1|
|2.0|bug1|1|
|3.0|feature1|1|
Step | Link | Inputs |
---|---|---|
Continue the Merge of release/3.0 branch changes to merge/tag_v_2_0_3_to_release_3_0 using following commands |
git add .
git commit -m "Resolve merge conflict by incorporating both suggestions"
git push -u origin merge/tag_v_2_0_3_to_release_3_0
Step | Link | Inputs |
---|---|---|
Merge Pull Request Merge tag v2.0.3 to release/3.0 | https://github.com/devopscodegen/branching-demo/pull/16 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge buttonClick on Delete branch button |
Add tag v3.0.2 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git tag v3.0.2
git push --tags
Step | Link | Inputs |
---|---|---|
Create branch merge/tag_v_1_0_4_to_release_2_0 from tag v1.0.4 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch merge/tag_v_1_0_4_to_release_2_0 v1.0.4
git checkout merge/tag_v_1_0_4_to_release_2_0
git push --set-upstream origin merge/tag_v_1_0_4_to_release_2_0
Step | Link | Inputs |
---|---|---|
Create pull request from merge/tag_v_1_0_4_to_release_2_0 branch to release/2.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/2.0...merge/tag_v_1_0_4_to_release_2_0 (opens in a new tab) | Click on Create pull request buttonAdd a title = Merge tag v1.0.4 to release/2.0 Assignees = Assign yourself Milestone = release/2.0 Click on Create pull request button |
Merge release/2.0 branch changes to merge/tag_v_1_0_4_to_release_2_0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git checkout merge/tag_v_1_0_4_to_release_2_0
git merge release/2.0
Step | Link | Inputs |
---|---|---|
Change demo.md file to have following contents |
|release|feature/bug/problem|commit|
|---|---|---|
|1.0|feature1|1|
|1.0|feature1|2|
|1.0|feature2|1|
|1.0|bug1|1|
|1.0|problem1|1|
|2.0|feature1|1|
|2.0|bug1|1|
Step | Link | Inputs |
---|---|---|
Continue the Merge of release/2.0 branch changes to merge/tag_v_1_0_4_to_release_2_0 using following commands |
git add .
git commit -m "Resolve merge conflict by incorporating both suggestions"
git push -u origin merge/tag_v_1_0_4_to_release_2_0
Step | Link | Inputs |
---|---|---|
Merge Pull Request Merge tag v1.0.4 to release/2.0 | https://github.com/devopscodegen/branching-demo/pull/17 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge buttonClick on Delete branch button |
Add tag v2.0.4 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/2.0
git tag v2.0.4
git push --tags
Step | Link | Inputs |
---|---|---|
Create branch merge/tag_v_2_0_4_to_release_3_0 from tag v2.0.4 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git branch merge/tag_v_2_0_4_to_release_3_0 v2.0.4
git checkout merge/tag_v_2_0_4_to_release_3_0
git push --set-upstream origin merge/tag_v_2_0_4_to_release_3_0
Step | Link | Inputs |
---|---|---|
Create pull request from merge/tag_v_2_0_4_to_release_3_0 branch to release/3.0 branch | https://github.com/devopscodegen/branching-demo/compare/release/3.0...merge/tag_v_2_0_4_to_release_3_0 (opens in a new tab) | Click on Create pull request buttonAdd a title = Merge tag v2.0.4 to release/3.0 Assignees = Assign yourself Milestone = release/3.0 Click on Create pull request button |
Merge release/3.0 branch changes to merge/tag_v_2_0_4_to_release_3_0 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git checkout merge/tag_v_2_0_4_to_release_3_0
git merge release/3.0
Step | Link | Inputs |
---|---|---|
Change demo.md file to have following contents |
|release|feature/bug/problem|commit|
|---|---|---|
|1.0|feature1|1|
|1.0|feature1|2|
|1.0|feature2|1|
|1.0|bug1|1|
|1.0|problem1|1|
|2.0|feature1|1|
|2.0|bug1|1|
|3.0|feature1|1|
Step | Link | Inputs |
---|---|---|
Continue the Merge of release/3.0 branch changes to merge/tag_v_2_0_4_to_release_3_0 using following commands |
git add .
git commit -m "Resolve merge conflict by incorporating both suggestions"
git push -u origin merge/tag_v_2_0_4_to_release_3_0
Step | Link | Inputs |
---|---|---|
Merge Pull Request Merge tag v2.0.4 to release/3.0 | https://github.com/devopscodegen/branching-demo/pull/18 (opens in a new tab) | Click on Squash and merge buttonClick on Confirm squash and merge buttonClick on Delete branch button |
Add tag v3.0.3 using following commands |
rm -rf /tmp/branching-demo
cd /tmp && git clone https://github.com/devopscodegen/branching-demo.git
cd branching-demo
git checkout release/3.0
git tag v3.0.3
git push --tags