If you are working on your project and ready to merge your release branch into master (production) then you can follow the below steps in git command line,
Step 1: Make sure your code is committed on your release branch, of the feature branch that you are going to commit to master.Step 2: Move current project to master branch
# git checkout master
Step 3: Merge your branch to master branch
# git merge release-branch
Step 4: Commit the branch into master branch
# git commit -a
βοΈThough we do not encourage to make use of the words master/slave as we really care about Diversity and Inclusion, this article is just for demonstration purpose and encourage everyone to make use of alternate words for repos like production/staging
More Posts related to Git,
- Change the default git branch name from master to main
- [Fixed] Git Clone git@github.com: Permission denied (publickey) Could not read from remote repository Fatal error
- [Solution] fatal: not a git repository (or any of the parent directories): .git
- [fix] zsh: command not found: git
- How to Install Git on Windows
- Setup Git + Visual Studio Code Tutorial
- How to undo last Git Commit on Local Repository?
- Install GitHub Command Line Tool on Mac
- How to Create a Git Branch in 6 Different ways
- Fix Git: Warning: could not find UI helper GitHub.UI on Windows
- Git Config Command - A Deep Dive
- Step-by-Step: How to delete a git branch from local as well as remote origin
- How to Add Git Bash Option to Windows Terminal List
- Command to Clone Repository Using Git Bash
- How to remove or unstage a file from git staged area
- Get the file location of git config values
- GitHub: How to Search Code
- How to check your installed version of Git
- Fix: error: src refspec master does not match any failed to push some refs to Git
- Git: Step-by-Step - How to Push Local Brach to GitHub
- How to Merge Branch into Master Branch
- fix fatal: --local can only be used inside a git repository error
- Fix: Git Pull Error: unable to resolve reference refs/remotes/origin/master: reference broken
- Change the default diff or commit editor for git
- Git Fix: fatal: refusing to merge unrelated histories Error
More Posts:
- How to set a Default Value for Optional is Empty or Null in Java - Java
- Fix SharePoint PowerShell error - The term Get-SPweb is not recognized as the name of a cmdlet function script file or operable program - SharePoint
- Java: Generate random numbers within a range - Java
- SharePoint error - An exception occurred when trying to issue security token: This implementation is not part of the Windows Platform FIPS validated cryptographic algorithms.. - SharePoint
- Add comma or semicolon at end of each line Notepad++ - NotepadPlusPlus
- How to install Java 11 on Mac - Java
- SDK Manager: failed to install : Android Studio on Windows - Android-Studio
- How to get Mobile Screen Resolution Width and Height programatically - Android