具有完整历史的 Linux 内核“历史”git 存储库

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/3264283/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 04:25:43  来源:igfitidea点击:

Linux kernel "historical" git repository with full history

linuxgitlinux-kernelkernel

提问by ashrugger

I think many developers like to investigate sources with the help of git gui blame. As explained in the commit for Linux-2.6.12-rc2(also mirrored at Github), it needs to have special historical Linux repository for this purpose.

我认为许多开发人员喜欢借助git gui blame. 正如Linux-2.6.12-rc2提交中所解释的(也在Github上有镜像),为此它需要有特殊的历史 Linux 存储库。

Linux-2.6.12-rc2

Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate “historical” git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git — space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it.

Let it rip!

Linux-2.6.12-rc2

初始 git 存储库构建。我不关心完整的历史,即使我们有它。如果我们愿意,我们可以稍后创建一个单独的“历史”git 存档,同时它在导入到 git 时大约为 3.2GB——空间只会使早期的 git 时代变得不必要地复杂,当我们没有很多良好的基础设施。

让它撕裂!

I have looked at a lot of the prepared historical repositories but I didn't find one containing changes going back to version zero, so I gave up and am asking this question here.

我查看了很多准备好的历史存储库,但我没有找到一个包含返回到版本零的更改,所以我放弃并在这里问这个问题。

回答by CesarB

Here is my setup.

这是我的设置。

I have a repository with a clone of the following remotes:

我有一个存储库,其中包含以下遥控器的克隆:

And the following grafts (info/grafts):

以及以下移植物 ( info/grafts):

1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 e7e173af42dbf37b1d946f9ee00219cb3b2bea6a
7a2deb32924142696b8174cdf9b38cd72a11fc96 379a6be1eedb84ae0d476afbc4b4070383681178

With these grafts, I have an unbroken view of the kernel history since 0.01. The first graft glues together the very first release in Linus' repository with the corresponding release of tglx/history.git. The second graft glues together tglx/history.gitand davej/history.git.

通过这些移植,我对自 0.01 以来的内核历史有了完整的看法。第一个移植将 Linus 存储库中的第一个版本与相应的tglx/history.git. 第二个接枝粘合在一起tglx/history.git并且davej/history.git

There are a few older versions missing, and the older versions have release granularity instead of patch granularity, but this is the best setup I know of.

缺少一些旧版本,旧版本具有发布粒度而不是补丁粒度,但这是我所知道的最佳设置。



Edit:Dave Jones pointed me to http://www.archive.org/details/git-history-of-linux, which seems to be exactly what you want.

编辑:Dave Jones 将我指向http://www.archive.org/details/git-history-of-linux,这似乎正是您想要的。

回答by Diomidis Spinellis

Here is a review of available 2018 options with a focus on tag availability and date correctness.

以下是对 2018 年可用选项的回顾,重点是标签可用性和日期正确性。

https://archive.org/download/git-history-of-linux/full-history-linux.git.tar

https://archive.org/download/git-history-of-linux/full-history-linux.git.tar

Developed by Dave Jones, and made available on archive.org.

由 Dave Jones 开发,并在archive.org.

  • Covers early versions to 2010.
  • 244,464 commits
  • Just 184 tags, covering versions in 2.6. The tags that should have been created for all versionsseem to be missing.
  • Early commits have realistic dates, but incorrect times (11:00:00 199X -0600).
  • Some dates seem to be incorrect. For example, both 2.1.110and 2.1.111are dated Wed May 20 11:00:00 1998 -0600, although the latest file in the 2.1.111snapshot is dated 1998-07-25 09:17.
  • The creation process is documented on GitHuband seems very thorough.
  • 涵盖 2010 年之前的早期版本。
  • 244,464 次提交
  • 仅 184 个标签,涵盖 2.6 中的版本。应该为所有版本创建的标签似乎丢失了。
  • 早期提交具有实际日期,但时间不正确 ( 11:00:00 199X -0600)。
  • 有些日期似乎不正确。例如,2.1.1102.1.111都是 dated Wed May 20 11:00:00 1998 -0600,尽管2.1.111快照中的最新文件是 dated 1998-07-25 09:17
  • 创建过程记录在 GitHub 上,看起来非常彻底。

https://git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git/

https://git.kernel.org/pub/scm/linux/kernel/git/tglx/history.git/

Created by Thomas Gleixner.

由托马斯·格莱克斯纳 (Thomas Gleixner) 创建。

  • Covers 2.4.0 to 2.6.12-rc2.
  • Contains 170 tags covering 2.5.X and 2.6.X.
  • 63,428 commits
  • Dates are correct.
  • Contains patches converted into commits.
  • 涵盖 2.4.0 到 2.6.12-rc2。
  • 包含 170 个标签,涵盖 2.5.X 和 2.6.X。
  • 63,428 次提交
  • 日期是正确的。
  • 包含转换为提交的补丁。

https://github.com/mpe/linux-fullhistory

https://github.com/mpe/linux-fullhistory

Created by Michael Ellerman, derived from work by Yoann Padioleau, based on historical trees reconstructed by Dave Jones and Thomas Gleixner, and Linus' mainline tree.

由 Michael Ellerman 创建,源自 Yoann Padioleau 的工作,基于 Dave Jones 和 Thomas Gleixner 重建的历史树以及 Linus 的主线树。

  • Covers full history
  • Provides only 558 tags, mostly starting at 2.0.0.
  • 790,471 commits
  • Same issues with dates as in Dave Jones's repo.
  • Uses replace objects instead of grafts.
  • 涵盖完整历史
  • 仅提供 558 个标签,大部分从 2.0.0 开始。
  • 790,471 次提交
  • 与 Dave Jones 的 repo 中的日期问题相同。
  • 使用替换对象而不是移植物。

https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/

https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/

Owned by the Linux history team.

归 Linux历史团队所有

  • Covers early versions to 2.6.33-rc5.
  • 1710 tags, starting with 0.10, covering most early versions.
  • 244,774 commits
  • Most historic versions are incorrectly dated Fri Nov 23 15:09:04 2007 -0500.
  • 涵盖 2.6.33-rc5 的早期版本。
  • 1710 个标签,从 0.10 开始,涵盖大部分早期版本。
  • 244,774 次提交
  • 大多数历史版本的日期都不正确Fri Nov 23 15:09:04 2007 -0500

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/

https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/

Modern Linux development.

现代 Linux 开发。

  • Covers 2.6.12-rc2 (2005) until today
  • 569 tags
  • 777,419 commits (August 2018)
  • Proper commits
  • 涵盖 2.6.12-rc2 (2005) 直到今天
  • 569个标签
  • 777,419 次提交(2018 年 8 月)
  • 正确提交

回答by Mike Frysinger

the referenced repos no longer exist. the new one is here: https://git.kernel.org/cgit/linux/kernel/git/history/history.git/

引用的 repos 不再存在。新的在这里:https: //git.kernel.org/cgit/linux/kernel/git/history/history.git/

if you're like me and want to keep some repos sep, you can leverage alternates with the graft to do so:

如果你像我一样想要保留一些 repos sep,你可以利用替代与移植来做到这一点:

# Same dir as main linux
$ git clone --bare git://git.kernel.org/pub/scm/linux/kernel/git/history/history.git
$ cd linux/.git/
$ echo ../../../history.git/objects >> objects/info/alternates
$ echo 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 e7e173af42dbf37b1d946f9ee00219cb3b2bea6a >> info/grafts
$ echo 7a2deb32924142696b8174cdf9b38cd72a11fc96 379a6be1eedb84ae0d476afbc4b4070383681178 >> info/grafts

回答by ashrugger

The best what I've found is git://git.kernel.org/pub/scm/linux/kernel/git/davej/history.git. History tracking there starts from Linux-0.01 but many comments are poor something like "Import 2.1.38pre1".

我发现的最好的是git://git.kernel.org/pub/scm/linux/kernel/git/davej/history.git。那里的历史跟踪从 Linux-0.01 开始,但许多评论都很糟糕,例如“导入 2.1.38pre1”。

Anyway there is a lot of knowledge.

反正有很多知识。

Thanks for help!

感谢帮助!