What Does "--remote" Actually Do In "git Submodule Update --remote"?
I just do not understand the help page of Git. So what does happen or what is the difference?
Assume I have a Git project A with a submodule B. Submodule B does have a submodule C. After cloning the repository A points to a specific commit of B. And B points to a specific commit of C.
If I am inside A I go to B by
Now I type
git submodule update --remote
git submodule update
What is the difference? Assuming that the remote server does have changes in A, B and C.
I guess that using "git submodule update --remote" keeps the reference to the specific version of C. Does using it without
--remote update to the latest version of C?
Suppose B is the only submodule of A.
cd A git ls-tree -r HEAD | grep commit
The output is something like
160000 commit 0814c6ba8f45829f04709c56118868d2483444c2 foo
foo is the submodule folder and
0814c6ba8f45829f04709c56118868d2483444c2 is its revision tracked by A's current commit.
git submodule update does something like
cd B git checkout 0814c6ba8f45829f04709c56118868d2483444c2
git submodule update --remote is like
cd B git fetch origin master git checkout origin/master
origin/master are used. If the branch is specified by
submodule.foo.branch = bar in
origin/bar are used.
- → Authenticate with a cookie using laravel 5.1 and jwt
- → Finding a specific GitLab tag from PHP
- → React: How to publish page on server using React-starter-kit
- → babel-loader, webpack, ES2015 modules: "Element type is invalid"
- → Create a function-attribute of a function, which is, in its turn, a method of an object literal
- → Model Validation in laravel 5.1 not working
- → GIT fatal: loose object
- → Laravel validation required rule not working
- → Axios array map callback
- → Where does this `webpack://` come from for `webpack-dev-middleware`?
- → error when trying to modify project in laravel forge
- → GitHub Pages and Jekyll content duplication and SEO issues
- → Use Laravel repositories with Datatables