[PATCH 0/2] Add submodule-support to git archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



This is a cleaned up version of my previous patches which allows git archive
to include submodule content in the archive output.

The main difference between this series and the previous ones is that the
behaviour of `git archive --submodules` are now predictable; the content
included from submodules is defined by the gitlink entries found when
traversing the <tree-ish> specified on the command line, and the set of
submodules to include are defined by specifying either `--submodules=all` or
`--submodules=checkedout` (which is the default mode of operation, i.e. what
you get by only specifying `--submodules`).

To make the `--submodules` option more userfriendly, any submodule repository
discovered during traversal will be registered as an alternate odb (this
will typically be required to make the inter-repository traversal succeed).

Finally, the option `--submodules=group:<name>` is not yet implemented. I
wanted to get these first two patches published early since they define the
semantics of the --submodules option. Adding a 'group' selector on top is
mostly a question of pulling information out of .gitmodules and .git/config,
i.e. not very exciting (but it will be done ;-)

Lars Hjemli (2):
  tree.c: allow read_tree_recursive() to traverse gitlink entries
  archive.c: add support for --submodules[=(all|checkedout)]

 Documentation/git-archive.txt |    5 ++
 archive.c                     |   81 +++++++++++++++++++++++++-
 archive.h                     |    4 +
 builtin-ls-tree.c             |    9 +--
 cache.h                       |    1 +
 merge-recursive.c             |    2 +-
 sha1_file.c                   |   11 +++-
 t/t5001-archive-submodules.sh |  129 +++++++++++++++++++++++++++++++++++++++++
 tree.c                        |   28 +++++++++
 9 files changed, 259 insertions(+), 11 deletions(-)
 create mode 100755 t/t5001-archive-submodules.sh

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux