From: W. Trevor King Date: Tue, 19 Feb 2013 10:05:02 +0000 (-0500) Subject: user-manual: Flesh out uncommitted changes and submodule updates X-Git-Tag: v1.8.1.5~2^2 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9148673377367db48183a33dcc53c828df397bfc;p=git user-manual: Flesh out uncommitted changes and submodule updates If you try and update a submodule with a dirty working directory, you get an error message like: $ git submodule update error: Your local changes to the following files would be overwritten by checkout: ... Please, commit your changes or stash them before you can switch branches. Aborting ... Mention this in the submodule notes. The previous phrase was short enough that I originally thought it might have been referring to the reflog note (obviously, uncommitted changes will not show up in the reflog either ;). Signed-off-by: W. Trevor King Signed-off-by: Junio C Hamano --- diff --git a/Documentation/user-manual.txt b/Documentation/user-manual.txt index acf872d893..bb03bc88b8 100644 --- a/Documentation/user-manual.txt +++ b/Documentation/user-manual.txt @@ -3739,7 +3739,9 @@ module a NOTE: The changes are still visible in the submodule's reflog. -This is not the case if you did not commit your changes. +If you have uncommitted changes in your submodule working tree, `git +submodule update` will not overwrite them. Instead, you get the usual +warning about not being able switch from a dirty branch. [[low-level-operations]] Low-level git operations