How does one recursively list the files in a git branch, including the contents within the commit in a submodule that the branch references? The branch is currently not checked out, and I want to access the contents without checking out that branch.
This is similar to this question, but the question I am raising is for querying a branch not currently checked out.
Unlike git ls-files
, git ls-tree
does not have a --recurse-submodules
option.