Warum schreibt "git submodule add ..." eher an stderr als an stdout?

Die Nachrich

Cloning into 'sub-mod'...
done.

nach einergit submodule add... Befehl wird in @ geschrieb stderr. Ich habe erwartet, dass die Nachricht an @ geschrieben wir stdout da ich glaube nicht, dass es darauf hinweist, dass mit dem Befehl ein Fehler aufgetreten ist.

Ich kann dies mit der folgenden Befehlsfolge reproduzieren:

rm   -rf /tmp/repo /tmp/module
mkdir    /tmp/repo /tmp/module

cd /tmp/module

git init  > /dev/null
echo "foo" > foo;
git add foo > /dev/null
git commit . -m "+ foo" > /dev/null


cd /tmp/repo

git init > /dev/null
git submodule add /tmp/module/ sub-mod 1> /dev/null

Wenn ich die Umleitung im letzten Befehl in @ ände... 2> /dev/null, es wird nichts gedruckt.

Antworten auf die Frage(2)

Ihre Antwort auf die Frage