From 5e495f81229d97f5585e06d0d45a39c5f407d026 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Uwe=20Kleine-K=C3=B6nig?= Date: Wed, 24 Oct 2018 10:04:52 +0200 Subject: howto/using-merge-subtree: mention --allow-unrelated-histories MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Without passing --allow-unrelated-histories the command sequence fails as intended since commit e379fdf34fee ("merge: refuse to create too cool a merge by default"). To setup a subtree merging unrelated histories is normal, so add the option to the howto document. Signed-off-by: Uwe Kleine-König Signed-off-by: Junio C Hamano diff --git a/Documentation/howto/using-merge-subtree.txt b/Documentation/howto/using-merge-subtree.txt index 1ae8d12..a499a94 100644 --- a/Documentation/howto/using-merge-subtree.txt +++ b/Documentation/howto/using-merge-subtree.txt @@ -33,7 +33,7 @@ Here is the command sequence you need: ---------------- $ git remote add -f Bproject /path/to/B <1> -$ git merge -s ours --no-commit Bproject/master <2> +$ git merge -s ours --no-commit --allow-unrelated-histories Bproject/master <2> $ git read-tree --prefix=dir-B/ -u Bproject/master <3> $ git commit -m "Merge B project as our subdirectory" <4> -- cgit v0.10.2-6-g49f6