我只是尝试删除特定提交背后的历史记录。我在Git: how to remove history before a specific commit以下命令中发现:
git fast-export master~5..master | (cd ../newrepo.git && git init . && git fast-import && git checkout)
我刚刚为我的案例更改了命令(我需要分支 ip6_dev 的最后 65 次提交):
git fast-export ip6_dev~65..ip6_dev | (cd ../puppet/ && git init . && git fast-import && git checkout)
当我运行命令时,我得到以下输出:
---------------------------------------------------------------------
Alloc'd objects: 10000
Total objects: 7985 ( 782 duplicates )
blobs : 4978 ( 0 duplicates 2304 deltas of 49
25 attempts)
trees : 2942 ( 782 duplicates 263 deltas of 29
28 attempts)
commits: 65 ( 0 duplicates 0 deltas of
0 attempts)
tags : 0 ( 0 duplicates 0 deltas of
0 attempts)
Total branches: 1 ( 1 loads )
marks: 1048576 ( 5043 unique )
atoms: 2438
Memory total: 2997 KiB
pools: 2606 KiB
objects: 390 KiB
---------------------------------------------------------------------
pack_report: getpagesize() = 65536
pack_report: core.packedGitWindowSize = 33554432
pack_report: core.packedGitLimit = 268435456
pack_report: pack_used_ctr = 358
pack_report: pack_mmap_calls = 65
pack_report: pack_open_windows = 1 / 1
pack_report: pack_mapped = 14669749 / 14669749
---------------------------------------------------------------------
fatal: You are on a branch yet to be born
我错过了什么?