我的 git repo 中有以下最近的历史记录。
* 7661a06 (HEAD, origin/devConsolidate, devConsolidate) Fix seg fault; OCBA intermediary compares by value() now also
| * 0bbe038 (origin/master, master) Flawed work no seedShift
|/
* 62fe9db Turn on OCBA_DEBUG; nan/inf values in OCBA prior to crash
* 71298c8 Turn on OCBA (non-intermediary); seg fault occurs
* 3693904 No OpenMP, no OCBA; no memory leaks on valgrind
* 9d5686c Disable OpenMP threads
* 80bbc3b Debug (-O0) build now throws exception also
* e148013 Post convert simulation4_NEJMdisutilities [] to at()
* 66cfba9 Post convert OCBA [] to at()
* 32db3be Pre convert OCBA [] to at()
* 4a9f25b Prep for debugging
* 907e88b Found error (vector out of bounds); need to fix from here
* ca6c639 Implement elapsed, iteration, and max time in OCBA
* db68c15 Fix SEG FAULT; OCBA now working (with intermediary)
* f1c6f05 GA now uses OCBA; GA/OCBA params from config file; produces SEG FAULT
| * 3b16dcf (origin/genCRNgraph, genCRNgraph) Generate QALYs test and control independent-sampling
|/
* 001eff2 Merge branch 'OCBAdev'
(的后代)之后的所有提交f1c6f05
都是为了调试问题。事后看来,我应该创建一个单独的分支来进行此调试,但我在master
. 现在,在 commit 中7661a06
,我已经修复了这个错误。
我想移动(倒带?)master
分支(或指针),使其位于 commit f1c6f05
。完成此操作后,我可以从提交之间的差异生成补丁7661a06
并将62fe9db
其应用于f1c6f05
. 结果,我的 git 日志的一部分应如下所示:
* 7661a06 (origin/devConsolidate, devConsolidate) Fix seg fault; OCBA intermediary compares by value() now also
| * 0bbe038 Flawed work no seedShift
|/
* 62fe9db Turn on OCBA_DEBUG; nan/inf values in OCBA prior to crash
.
.
.
* db68c15 Fix SEG FAULT; OCBA now working (with intermediary)
| * <HASH> (HEAD, origin/master, master) Fix problem and rewind master
|/
* f1c6f05 GA now uses OCBA; GA/OCBA params from config file; produces SEG FAULT
| * 3b16dcf (origin/genCRNgraph, genCRNgraph) Generate QALYs test and control independent-sampling
|/
* 001eff2 Merge branch 'OCBAdev'
我将使用哪些命令来实现所有这些?具体来说,我将如何:(1)移动主机,(2)生成补丁,(3)应用补丁?