From: Stavros Liaskos <st.liaskos@gmail.com>
To: git@vger.kernel.org
Subject: subtree merging fails
Date: Tue, 7 Feb 2017 09:16:46 +0100 [thread overview]
Message-ID: <CAEXhnECi3LvSA92dSjL5PZ1Lx9p1PWELS04nmfJW=8K9o4T-0Q@mail.gmail.com> (raw)
Following the instructions here:
https://git-scm.com/book/en/v1/Git-Tools-Subtree-Merging
will lead to an error.
In particular, if the subtree is merged and then updated, this command
that is supposed to update the local subtree fails with a fatal:
refusing to merge unrelated histories error.
$ git merge --squash -s subtree --no-commit rack_branch
A workaround could be using the --allow-unrelated-histories option
$ git merge --squash --allow-unrelated-histories -s subtree
--no-commit rack_branch
But this completely destroys my project by pushing the subtree
contents into a completely irrelevant directory in my project (no in
the subtree).
Any ideas??
https://github.com/git/git-scm.com/issues/896#issuecomment-277587626
next reply other threads:[~2017-02-07 8:16 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-02-07 8:16 Stavros Liaskos [this message]
2017-02-07 14:59 ` subtree merging fails Samuel Lijin
2017-02-07 18:44 ` David Aguilar
2017-02-08 10:42 ` Stavros Liaskos
-- strict thread matches above, loose matches on Subject: below --
2017-02-06 8:48 Stavros Liaskos
2017-02-06 17:08 ` Johannes Schindelin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: http://vger.kernel.org/majordomo-info.html
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAEXhnECi3LvSA92dSjL5PZ1Lx9p1PWELS04nmfJW=8K9o4T-0Q@mail.gmail.com' \
--to=st.liaskos@gmail.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://80x24.org/mirrors/git.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).