0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

[git] submoduleの取得時にそれがもっているsubmoduleも取得する

Last updated at Posted at 2025-06-01

結論

git submodule init
git submodule update --init --recursive

もしくは

git clone --progress --recursive "リポジトリのURL"

解説

コマンドの意味
--init
初めてクローンしてきたリポジトリに対して、.gitmodules に記載されたサブモジュールを初期化する。

--recursive
ネストされたサブモジュールも含めて再帰的に処理する。

update
サブモジュールの内容を指定されたコミットに更新(checkout)する。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?