Click only the last commit with TortoiseGit

I want to push only the last message from TortoiseGit to the sourceforge repository. All previous ones should not be hustled. It says here that I can create a new branch and click this. But the new branch has all the previous commits, and not just the last one.

What am I doing wrong?

Thank!

+3
source share
1 answer

I think this is primarily a misunderstanding of how git works. When you click commit, if that commit has a parent, git will make sure that this parent is also in the remote repository. In addition to the rare clones (which may be useful for conserving bandwidth and / or disk usage, but impose some restrictions on how you can interact with remote repositories), git is designed to ensure that the database of objects is complete and consistent. The completeness / consistency will be broken if you can push commit without having the parents also be in the repository. Thus, by design, you cannot just push a single commit without git to make sure that the line fix is ​​maintained.

, , : 1) , , , (, rebase , , , , ) 2) , , , - , git checkout -b somebranch --orphan git, .

+2

All Articles