git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 0/3] sane rebase/stash support with submodules

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
May 14, 2008, 17:03 UTC
Message-ID
<alpine.DEB.1.00.0805141802480.30431@racer>

Submodules are special in that they cannot be blindly updated with a checkout. Indeed, submodules do not even have to be checked out (and in that case, must not be updated). It is the user's responsibility to care about the working tree state of submodules.

Therefore, it does not make sense in stash/rebase to test for dirty submodules: they would not be updated anyway.

This patch series does exactly that: working tree states of submodules are ignored with stash and rebase, by calling update-index and the diff programs with the freshly introduced --ignore-submodules option.

Johannes Schindelin (3):
  diff options: Introduce --ignore-submodules
  Teach update-index about --ignore-submodules
  Ignore dirty submodule states during rebase and stash
 Documentation/diff-options.txt     |    3 +
 Documentation/git-update-index.txt |    5 ++
 builtin-update-index.c             |    4 ++
 cache.h                            |    1 +
 diff.c                             |    9 ++++
 diff.h                             |    1 +
 git-rebase--interactive.sh         |   11 ++--
 git-rebase.sh                      |    8 ++--
 git-stash.sh                       |    6 +-
 read-cache.c                       |    4 ++
 t/t7402-submodule-rebase.sh        |   92 ++++++++++++++++++++++++++++++++++++
 11 files changed, 132 insertions(+), 12 deletions(-)
 create mode 100755 t/t7402-submodule-rebase.sh
Next: Johannes Schindelin
Message 1 of 12 in “sane rebase/stash support with submodules”
  1. 0/3 sane rebase/stash support with submodulesJohannes Schindelin, May 14, 2008
  2. 1/3 diff options: Introduce --ignore-submodulesJohannes Schindelin, May 14, 2008
  3. Junio C HamanoMay 14, 2008
  4. Johannes SchindelinMay 14, 2008
  5. Junio C HamanoMay 14, 2008
  6. Johannes SchindelinMay 14, 2008
  7. Junio C HamanoMay 14, 2008
  8. Johannes SchindelinMay 15, 2008
  9. Junio C HamanoMay 15, 2008
  10. Johannes SchindelinMay 15, 2008
  11. 2/3 Teach update-index about --ignore-submodulesJohannes Schindelin, May 14, 2008
  12. 3/3 Ignore dirty submodule states during rebase and stashJohannes Schindelin, May 14, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.