threads / discuss / 29438

Correct way to pull using subtree merge without guesswork?

Subject: Correct way to pull using subtree merge without guesswork?

## tl;dr

2 messages between Jan 24, 2012 and Jan 24, 2012.

replies: 1people: 2as markdown or json

Manuel Reimer· Jan 24, 2012, 17:49 UTC · lore
Hello,

can someone please tell me, if this is the correct syntax for using "git pull" to pull in "subtree merging strategy", if I don't want to allow git to guess where to do the changes:

git pull -s subtree -X subtree=path/to/subtree externalproject master

Returns with success, but is "-X subtree=" the right way to force a subtree path and disallow git to autodetect the subtree?

$ git --version git version 1.7.4.4

Thank you very much in advance
Yours
Manuel
Junio C Hamano· Jan 24, 2012, 18:27 UTC · re: Manuel Reimer · lore

Re: Correct way to pull using subtree merge without guesswork?

Manuel Reimer <Manuel.Spam@nurfuerspam.de> writes:
> git pull -s subtree -X subtree=path/to/subtree externalproject master
>
> Returns with success, but is "-X subtree=" the right way to force a
> subtree path and disallow git to autodetect the subtree?

More or less. Note that with the syntax, you cannot still express the distinction between mapping the root of external to path/to/subtree of your current tree and mapping the other way around, but that is not an issue in practice.

By the way, I had an impression that "-X subtree" makes "-s subtree" redundant and unnecessary.

← back to recent threads