diff options
author | Avery Pennarun <apenwarr@gmail.com> | 2009-04-24 17:42:33 -0400 |
---|---|---|
committer | Avery Pennarun <apenwarr@gmail.com> | 2009-04-24 17:42:33 -0400 |
commit | 2c71b7c46d1ff887fb276a9d42346678a2948a00 (patch) | |
tree | 8592a69af509d2d22629be51f5fc6bb8239c4e33 /git-subtree.sh | |
parent | Added a --onto option, but it's so complicated I can't tell if it works. (diff) | |
download | tgif-2c71b7c46d1ff887fb276a9d42346678a2948a00.tar.xz |
Hmm... can't actually filter rev-list on the subdir name.
Otherwise we can't keep track of parent relationships. Argh.
This change makes it "work", but we get a bunch of empty commits.
Diffstat (limited to 'git-subtree.sh')
-rwxr-xr-x | git-subtree.sh | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/git-subtree.sh b/git-subtree.sh index 7e1707ae2a..1e1237f520 100755 --- a/git-subtree.sh +++ b/git-subtree.sh @@ -173,28 +173,31 @@ cmd_split() cache_setup || exit $? if [ -n "$onto" ]; then - echo "Reading history for $onto..." + echo "Reading history for --onto=$onto..." git rev-list $onto | while read rev; do # the 'onto' history is already just the subdir, so # any parent we find there can be used verbatim + debug " cache: $rev" cache_set $rev $rev done fi unrevs="$(find_existing_splits "$dir" "$revs")" - git rev-list --reverse --parents $revs $unrevs -- "$dir" | + debug "git rev-list --reverse $revs $unrevs" + git rev-list --reverse --parents $revs $unrevsx | while read rev parents; do - exists=$(cache_get $rev) - newparents=$(cache_get $parents) debug - debug "Processing commit: $rev / $newparents" - + debug "Processing commit: $rev" + exists=$(cache_get $rev) if [ -n "$exists" ]; then debug " prior: $exists" continue fi + debug " parents: $parents" + newparents=$(cache_get $parents) + debug " newparents: $newparents" git ls-tree $rev -- "$dir" | while read mode type tree name; do |