📘
Git-Help
Git Cheatsheet
  • A Simple Git Help
  • Basics
  • Git Branching
  • Pull Request
  • Submodules
  • Commands / Actions
    • Commit changes to other branch
    • git log
    • git status
    • git init
    • Amend a commit
    • Reset a file or full
    • Undo git add
    • Get remote repo url
    • Add or Set Remote URL
    • delete branch
  • Credits & Other
    • Other good links
    • Credits
Powered by GitBook
On this page

Was this helpful?

Submodules

Imagine a situation where you want to include a project/code(lets call it Project-Common-Code) into two separate git projects(Project-A and Project-B). You can easily copy the Project-Common-Code into Project-A and Project-B, but everytime the Project-Common-Code is updated you have to copy that again to Project-A and Project-B. You may also face merge issues if you modify them. To avoid such situations you can make the Project-Common-Code as a submodule inside the Project-A and Project-B. And you can independently modify that project and pull them into Project-A and Project-B.

PreviousPull RequestNextCommit changes to other branch

Last updated 3 years ago

Was this helpful?