Skip to content

Instantly share code, notes, and snippets.

@cnlohr
Last active June 18, 2025 16:46
Show Gist options
  • Save cnlohr/04de6edd3e2a75face0a68c53be2017e to your computer and use it in GitHub Desktop.
Save cnlohr/04de6edd3e2a75face0a68c53be2017e to your computer and use it in GitHub Desktop.
Git forgot to clone recursively (forgot to check out with recurse submodules)
@officialcjunior
Copy link

Thank you!
I visit this gist almost on a monthly basis.

@jakedowns
Copy link

jakedowns commented Sep 29, 2022

note, if the original repo had it's sub-repos pinned to specific checkouts, it seems like this method of cloning them is getting the latest versions, which could break things. :G

@cnlohr
Copy link
Author

cnlohr commented Nov 9, 2022

Do you know if there's another option for your preferred behavior?

@GreenLightning
Copy link

@jakedowns @cnlohr If you want to check out the commits as specified in the parent repo, remove the --remote option.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment