How to delete all files from one branch and copy from another branch

Asked

Viewed 35 times

0

I have a branch called stage and another dev dev gets all temporary branchs from Features and fix but not all of them are approved and go to Stage. The problem is that dev has so many commits that have never been approved, that is codes that are there, but are no longer in the Stage.

How do I delete all files from dev and make a clone of Stage for the dev? I mean, dev will be a clone of my current Stage

I thought it would be something like rebase, but reading it seems to me that it is to change the history, I do not want to change the history, dev historical alias does not matter, I just want to make the dev to be a clone of my current Stage.

NOTE: All branches are synchronized with a web versioner and distributed to multiple computers.

  • Why don’t you erase the branch and recreate from the other?

  • fix...@bfavaretto If I delete location I will have no problem trying to push after?

  • But why delete only the location? Delete the remote too.

  • and then recreates? the people who have it site will have trouble to pull?

  • The others would need to do a new pull. It has other forms, but it is more complex and I can not explain

No answers

Browser other questions tagged

You are not signed in. Login or sign up in order to post.