无法通过git rebase对提交进行重新排序

无法通过git rebase对提交进行重新排序,git,Git,我想交换蓝盒子和红盒子 但我无法使用git rebase 1e74133实现这一点,然后更改提交位置 我收到了错误信息 它告诉我问题在哪里 高级收藏 但这无助于git添加高级集合 在这种情况下,我不知道如何交换提交顺序 怎么做?谢谢 % grbi 1e74133

我想交换蓝盒子和红盒子

但我无法使用git rebase 1e74133实现这一点,然后更改提交位置

我收到了错误信息

它告诉我问题在哪里 高级收藏

但这无助于git添加高级集合

在这种情况下,我不知道如何交换提交顺序

怎么做?谢谢

% grbi 1e74133                                                                                                                               (git)-[master]
error: Updating the following directories would lose untracked files in it:
    04-adavanced_collection/python_hw

Aborting
Could not apply eff7b98ad02c49ab737a23fc5047a6b26da683b4... rename course 04


Untracked files:
  (use "git add <file>..." to include in what will be committed)

    04-adavanced_collection/
重定基址后的预期历史

* e7a1f28 hw5:list all not-fixed common bugs
* 42d6ede hw5: convert bugs into a list
* d48da21 hw5: clean the common bug text
* eb353e3 hw5_sol: read line and find the target line
* 404184c add solution for HW5 : common bugs

* 073f187 ignore useless files
* f64bbdd add course06 lecture
* 16dc565 add course06 resource
* eff7b98 rename course 04  

* 1e74133 update 2015-01-23 course info 

这里的答案完全取决于这些提交中的实际内容。您最好的做法可能是让一位对git有更多经验的同事查看您的树,并找出rebase失败的原因

发生此类再基础故障的一些典型情况如下:

1提交会删除一个文件,并且您会在修改文件的较早提交之前重新设置该提交的基础,因此现在提交会在重新设置基础期间尝试修改已删除的文件

2反向-提交会添加一个文件,稍后提交会更改该文件,您会将稍后提交移动到较早提交之前

* e7a1f28 hw5:list all not-fixed common bugs
* 42d6ede hw5: convert bugs into a list
* d48da21 hw5: clean the common bug text
* eb353e3 hw5_sol: read line and find the target line
* 404184c add solution for HW5 : common bugs

* 073f187 ignore useless files
* f64bbdd add course06 lecture
* 16dc565 add course06 resource
* eff7b98 rename course 04  

* 1e74133 update 2015-01-23 course info