【问题标题】:What is the equivalent of hg clone --noupdate in git?git中的hg clone --noupdate等价物是什么?
【发布时间】:2020-05-16 11:46:51
【问题描述】:

我们已经使用hglib 得到了一个完整的系统,并且我们正在创建一个抽象层来定制系统的一些需求,但我无法理解相当于

hg clone source destination --noupdate 在 Git 中

-U --noupdate the clone will include an empty working directory (only a repository)

https://www.mercurial-scm.org/repo/hg/help/clone

提前谢谢你。

【问题讨论】:

  • 不完全一样(嗯,根本不一样:它比以前更糟糕了)但考虑git clone --bare
  • @torek git clone --no-checkout 怎么样?不一样吗?
  • git clone --no-checkout 肯定更接近hg clone -U。使用哪个取决于您计划对生成的存储库做什么。

标签: git version-control mercurial equivalent version-control-migration


【解决方案1】:

经过大量网页浏览,找到了一个不错的等价物:

git clone --no-checkout

我的用例:

我们想要某种裸克隆,就像 --noupdate 标志对 HG 所做的那样。

从技术上讲,在 git 中我猜它只是克隆而不检查它。

如果其他人有好的答案,欢迎您编辑此答案。

【讨论】:

  • 你想要一个裸克隆(一个完全没有工作副本的,git clone --bare
猜你喜欢
  • 2017-05-30
  • 2021-11-24
  • 1970-01-01
  • 2011-11-29
  • 2011-01-17
  • 2021-08-26
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多