My current branch is "feature\COMS-260". In the remote there is one branch "hotfix/4.6.7". For some reason, my branch code is mess up.
I want to use all files in branch "hotfix/4.6.7" to overwrite my local branch "feature\COMS-260".
How to do it? I need Git commands or Sourcetree details.
Your description does not give all needed information - as Seth asked, it's crucial whether some of your erroneous files from branch "feature\COMS-260" are already pushed to your remote repository and if someone else is tracking branch "feature\COMS-260" in this case.
Also the information is missing whether some commits on your branch "feature\COMS-260" should be preserved, or whether all commits on branch "feature\COMS-260" are a mess (and maybe deleted therefore).
I'll try to describe the solutions for the two thinkable situations (assuming some of your commits on branch "feature\COMS-260" should be preserved):
******* To be on the safe side, make a backup of your local repository in case of some failure ...*******
Case 1: erroneous files already pushed to branch "feature\COMS-260"
Case 2: erroneous files NOT already pushed to branch "feature\COMS-260"
Supported Platforms macOS Windows To make using Sourcetree as simple yet powerful as possible we embed (bundle) dependencies such as Git, Git LFS, and Mercurial. We strive to keep these...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG
You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs