git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
* The meaning of the '+' before the submodule hash.
@ 2021-04-21 14:19 Hongyi Zhao
  2021-04-21 14:25 ` Taylor Blau
  0 siblings, 1 reply; 3+ messages in thread
From: Hongyi Zhao @ 2021-04-21 14:19 UTC (permalink / raw)
  To: Git List

Hi,

See the following output given below by `git submodule status`:

$ git submodule status
+c7b9787f0b7826a87f07ce00cbfe4947b8521101 external/devxlib (heads/master)
 d0197c76ae76bbf4d3fed20444fac31af550069d external/eigensolver_gpu
(v0.3.1-7-gd0197c7)
+6fef49bcfc4a380432f15734ed0ca1f0b0388977 external/fox (4.1.2-89-g6fef49b)
+4b3c7c249f6a2cfed76603d9987cf5164fa6f9e1 external/lapack
(v3.7.0-1026-g4b3c7c249)
+2899044d2a6828aa16e0189913662bc35ce8f645 external/mbd (0.12.1-43-g2899044)
+2b9973c12e85397fa9564370f6cced16f8428834 external/wannier90
(v3.1.0-35-g2b9973c)

What's the meaning of the '+' sign at the beginning? Why do some
submodules have this symbol, but some submodules don't?

Regards
-- 
Assoc. Prof. Hongyi Zhao <hongyi.zhao@gmail.com>
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: The meaning of the '+' before the submodule hash.
  2021-04-21 14:19 The meaning of the '+' before the submodule hash Hongyi Zhao
@ 2021-04-21 14:25 ` Taylor Blau
  2021-04-21 14:36   ` Hongyi Zhao
  0 siblings, 1 reply; 3+ messages in thread
From: Taylor Blau @ 2021-04-21 14:25 UTC (permalink / raw)
  To: Hongyi Zhao; +Cc: Git List

On Wed, Apr 21, 2021 at 10:19:25PM +0800, Hongyi Zhao wrote:
> What's the meaning of the '+' sign at the beginning? Why do some
> submodules have this symbol, but some submodules don't?

There are three symbols, 'U', '-', and '+'. From the documentation [1],
they mean:

    Each SHA-1 will possibly be prefixed with `-` if the submodule is not
    initialized, `+` if the currently checked out submodule commit does not
    match the SHA-1 found in the index of the containing repository and `U`
    if the submodule has merge conflicts.

[1]: https://git-scm.com/docs/git-submodule#Documentation/git-submodule.txt-status--cached--recursive--ltpathgt82308203

Thanks,
Taylor

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: The meaning of the '+' before the submodule hash.
  2021-04-21 14:25 ` Taylor Blau
@ 2021-04-21 14:36   ` Hongyi Zhao
  0 siblings, 0 replies; 3+ messages in thread
From: Hongyi Zhao @ 2021-04-21 14:36 UTC (permalink / raw)
  To: Taylor Blau; +Cc: Git List

On Wed, Apr 21, 2021 at 10:25 PM Taylor Blau <me@ttaylorr.com> wrote:
>
> On Wed, Apr 21, 2021 at 10:19:25PM +0800, Hongyi Zhao wrote:
> > What's the meaning of the '+' sign at the beginning? Why do some
> > submodules have this symbol, but some submodules don't?
>
> There are three symbols, 'U', '-', and '+'. From the documentation [1],
> they mean:
>
>     Each SHA-1 will possibly be prefixed with `-` if the submodule is not
>     initialized, `+` if the currently checked out submodule commit does not
>     match the SHA-1 found in the index of the containing repository and `U`
>     if the submodule has merge conflicts.
>
> [1]: https://git-scm.com/docs/git-submodule#Documentation/git-submodule.txt-status--cached--recursive--ltpathgt82308203

Thank you very much for pointing out this document information to me.
The above submodules status for my case were achieved by the following
command:

$ git submodule update --init --recursive --remote

As you can see, this will cause the status denoted by '+', i.e., the
currently checked out submodule commit does not match the SHA-1 found
in the index of the containing repository. I'm not sure if this is
harmful.

HY

> Thanks,
> Taylor



-- 
Assoc. Prof. Hongyi Zhao <hongyi.zhao@gmail.com>
Theory and Simulation of Materials
Hebei Polytechnic University of Science and Technology engineering
NO. 552 North Gangtie Road, Xingtai, China

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-04-21 14:37 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-04-21 14:19 The meaning of the '+' before the submodule hash Hongyi Zhao
2021-04-21 14:25 ` Taylor Blau
2021-04-21 14:36   ` Hongyi Zhao

Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).