git rebase - Extract out changes to single file in a range of git commits -


itemprop = "text">

The project data for the construction system I'm usually working on is committed to the local store, before it was fully built Can go This - along with my usual habit, often bribe before pushing public repo - this means that I have a heap at the top of the remote stem, most of them have sent messages like "s" because I know That they will be crushed

My position here is automating one step to reserve the list of commitments. I know that all the changes made in a certain file should not be sent to the public repo, and I am trying to edit each comma in a different way to split it into that file, which I'll squash later Rebase.

For example, here it is at the top if the head of origin:

  * 6f42745 (head, master-dev) s * b33bc68 s * 0b787e8 s * 3d47e 9e s * ae45dec brought PKG up-to-date with Master Branch * dd87ec1 s * 96fd4ef DD: Dave Dev * 422cf73 (Original / Master, Master) Add missing construction script.   

I want to redo all the commitments from Master .. Master-Dave, remove the changes in ./file.txt:

 < Code> * 6f42745 (Head, Master-Dave) S * ------- DD (Change in FileText) * B 33 BC 68 S * ------- DD (change in filetax) * 0b 787 e 8s * --- ---- DD (change in file.txt) * 3D 47E9Ss * AITDAC brought PKG up-to-date with master branch * DD 87C1S * 96FD4 IF DD: Dave Dev * 422cf73 (Original / Month Master,   

And finally, I will run the GIT Rebase-i root / master, all the "DDs" are done together with the squash, in all "S" PKG Up to date is brought to the master branch ", order them again, update the master, and push the original, ending in the end:

  * ----- - (Head, Master-Dave) DD: Dave Dev * ------- (Original / Master, Master) brought PKG up-to-date with Master Branch * 422cf73 missing building scraps The Pts Add   

I'm sure the answer git with filter-branch complete, but I do not know how.


Edit:

  • - Fixes the jar of "autosquash", but this is not the main question I still do not know is that a specific file How to split the changes in, which before that I have to squash them.
  • The blur / clear filters are nifty, but I'm not doing keyword replacement, and I do not think the changes that I keep on my personal branch are being adequately estimated for the script. I feel that I am always committed to at least one public master.

    This will tell you how to do autospection Instead of marking the commitment with it, mark it with a squash.

    It seems that for all DD commit you should maintain your branch. Then manage to merge with the main branch.

    If you want a change in the file, then focus on the skull / clean script, due to the installation of the environment. This will make you relevant changes to the file and leave any changes that are only for your environment. This is usually a DB connection string which is different from a god.

    Take a look here:

Comments