Subject: Re: Changled submodule cannot be "git added"

From: Jens Lehmann <[email-masked]>
Date: Tue, 15 Jun 2010 18:05:41 +0200

Am 15.06.2010 09:37, schrieb Nico -telmich- Schottelius:
> Nico -telmich- Schottelius [Tue, Jun 15, 2010 at 09:25:14AM +0200]:
>> % git status
>> #       modified:   modules/tftpd_hpa (modified content)
> 
> Ok, found out that I changed stuff within modules/tftpd_hpa, instead of
> merging from the source.

To make such surprises visible is the intent of showing "(modified
content)" here.

> Imho the git status output is a bit misleading, as I assume that
> I can git add stuff that's modified.

Maybe you just overlooked this line in the output of "git status":
"(commit or discard the untracked or modified content in submodules)"

> Regarding the other problem
> 
>> - Why does git checkout not remove modules/ethz_systems_private/,
>>   when switching from the master to the private branch?
>>   (the module is only registered in the private branch)
> 
> I'm still not sure what's the reason for that.

Because there might be stuff in there which is not tracked but you
might hate loosing by switching a branch.