Git: ¿cómo eliminar commits repetidos que aparecen en otra twig?

Tengo una situación en la que mis twigs se ven así:

* d3b91f2 (HEAD, origin/narrowdown_lblrtmprogram, narrowdown_lblrtmprogram, lowercase_main_src_code) resolve gi t-pull conflict. gitignore *.mod and *.so |\ | * 0ed828f number all the markers which a typical run goes past | * 7a9fd6a gitignore *.o and lblrtm executables | * 40e824a stop tracking lblrtm/lblrtm_v12.2_linux_intel_dbl | * cfb6866 stop tracking some previously tracked files but are now in .gitignore | * 314451c lay down markers in main program | * a0d6edf gitignore *.mod | * 5e9352a gitignore `runs/` directory * | 2e48384 number all the markers which a typical run goes past * | a0db0ed gitignore *.o and lblrtm executables * | df52ddc stop tracking some previously tracked files but are now in .gitignore * | 37fc6d1 lay down markers in main program * | 9deee6a gitignore *.mod * | 9ae357a (origin/trace_lblrtm_lw_flux_calc, trace_lblrtm_lw_flux_calc) gitignore runs/ * | 4ce55a0 gitignore *.o and lblrtm executables * | 3691140 stop tracking lblrtm/lblrtm_v12.2_linux_intel_dbl |/ | * 3c8edd0 (origin/master, master) gitignore runs/ | * 969a8e1 gitignore *.o and lblrtm executables |/ * 11ed99d Revert "Add write() statements to mark path through lblrtm source code for example solar run" 

Parece que hay dos twigs que se fusionan en la confirmación más alta d3b91f2 . Sin embargo, los commits de 3691140 a 2e48384 son efectivamente los mismos que los de 5e9352a a 0ed828f . ¿Hay alguna manera de deshacerse de esos commits networkingundantes de 5e9352a a 0ed828f ? Porque mirando

 [jk@nuwaln01 aerlbl_v12.2_package]$ git log -10 narrowdown_lblrtmprogram --oneline d3b91f2 resolve git-pull conflict. gitignore *.mod and *.so 2e48384 number all the markers which a typical run goes past a0db0ed gitignore *.o and lblrtm executables df52ddc stop tracking some previously tracked files but are now in .gitignore 37fc6d1 lay down markers in main program 9deee6a gitignore *.mod 9ae357a gitignore runs/ 4ce55a0 gitignore *.o and lblrtm executables 3691140 stop tracking lblrtm/lblrtm_v12.2_linux_intel_dbl 0ed828f number all the markers which a typical run goes past 

y

 [jk@nuwaln01 aerlbl_v12.2_package]$ git log -10 --oneline lowercase_main_src_code d3b91f2 resolve git-pull conflict. gitignore *.mod and *.so 2e48384 number all the markers which a typical run goes past a0db0ed gitignore *.o and lblrtm executables df52ddc stop tracking some previously tracked files but are now in .gitignore 37fc6d1 lay down markers in main program 9deee6a gitignore *.mod 9ae357a gitignore runs/ 4ce55a0 gitignore *.o and lblrtm executables 3691140 stop tracking lblrtm/lblrtm_v12.2_linux_intel_dbl 0ed828f number all the markers which a typical run goes past 

estos commits no parecen pertenecer a ninguna twig narrowdown_lblrtmprogram o branch narrowdown_lblrtmprogram , por lo que no puedo usar git branch -d .

la rebase interactiva podría ser útil.

 git rebase -i 11ed99d 

y la bandera confirma que quiere borrar con d marcador.

Solo asegúrate de tener una twig de respaldo o tendrás que hacer un git reflog si algo falla.