Jorge Orpinel Jorge Orpinel - 1 month ago 8
Git Question

assertion failed errors when trying to git subtree split

I have a private GitHub repo (which I can't share here) cloned locally. I want to split a subfolder in this repo into a new subtree repo. I'm following these instructions Using Git subtrees for repository separation (under Splitting code into its own repository).

My specific command is:

> git subtree split -P .\plugins\rg-feed-client -b rg-feed-client


however it fails with exactly 24 "assertion failed" error messages that look like this:

1/ 26 (0)2/ 26 (1)assertion failed: [ plugins/rg-feed-client = .\plugins\rg-fee
3/ 26 (2)assertion failed: [ plugins/rg-feed-client = .\plugins\rg-feed-client ]
...
26/ 26 (25)assertion failed: [ plugins/rg-feed-client = .\plugins\rg-feed-client ]


If I try any other subfolder, the exact same happens. I have no idea what may be wrong here... HELP!

My repo has 2 remotes: origin, and a remote for an existing subtree that I added to my repo.

Answer

This was probably due to the backslashes in --prefix (I was running Windows back then.)

p.s. no one was able to answer this but they felt free to down-vote my Q? Of course I did a research effort, some people here are just pr1cks