author | Elijah Newren <newren@gmail.com> | |
Sat, 17 Jul 2010 17:00:50 +0000 (11:00 -0600) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Mon, 19 Jul 2010 18:12:15 +0000 (11:12 -0700) | ||
commit | 4087a02e452aafd0e9a6c3471c40fe76d6aafbe4 | |
tree | 678629b4fe58e1c6a8ed175aabd75345fb54fe23 | tree | snapshot |
parent | 0ad0a61f05fe521a63ade9bfafd2f589fba0df33 | commit | diff |
fast-export: Fix dropping of files with --import-marks and path limiting
Since fast-export operates by listing file changes since the (first) parent
commit, when using --import-marks and path limiting and using a wider list
of paths than in previous runs, files from the new path(s) will silently be
omitted from the result unless or until a commit which explicitly changes
those files. The resulting repository in such cases is broken and makes no
sense.
This commit fixes this by having fast-export work with complete trees
instead of incremental changes (when both --import-marks and path limiting
are used). It works by issuing a 'deleteall' directive with each commit and
then listing the full set of files that make up that commit, rather than
just showing the list of files that have changed since the (first) parent
commit.
Signed-off-by: Elijah Newren <newren@gmail.com>
Acked-by: Sverre Rabbelier <srabbelier@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Since fast-export operates by listing file changes since the (first) parent
commit, when using --import-marks and path limiting and using a wider list
of paths than in previous runs, files from the new path(s) will silently be
omitted from the result unless or until a commit which explicitly changes
those files. The resulting repository in such cases is broken and makes no
sense.
This commit fixes this by having fast-export work with complete trees
instead of incremental changes (when both --import-marks and path limiting
are used). It works by issuing a 'deleteall' directive with each commit and
then listing the full set of files that make up that commit, rather than
just showing the list of files that have changed since the (first) parent
commit.
Signed-off-by: Elijah Newren <newren@gmail.com>
Acked-by: Sverre Rabbelier <srabbelier@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/fast-export.c | diff | blob | history | |
t/t9350-fast-export.sh | diff | blob | history |