I'm trying to migrate my (huge) p4 repo to git.
I did p4 clone //proj/branchA@all and it did what was expected - made a repo with the history up to where this branches was created. The issue is that this branch is created from another one, so the first 'commit' is Branching //proj/branchB/... to //proj/branchA/....
Now, when I try to see Annotations using Intellij Idea, I can see the changes all the way up to the creation of the file. The command that Idea runs is filelog -i -l -t -m 1000 /path/to/file. The log is as follows:
...
... ... branch into //proj/branchC/.../file#1
... ... branch into //proj/branchX/.../file#1
change #1234 edit on ...
... ... branch into //proj/branchY/.../file#1
...
Now obviously there is a way to follow the file and see changes beyond what is present on the current branch. Can someone help me to transfer all that history using git p4 or any other service?
What you can do it clone the two branches to separate repos, then use git to combine them together.
Unfortunately I can't remember the full details for how to graft the branches together.
https://superuser.com/questions/1005412/how-can-i-make-a-set-of-commits-the-children-of-another-commit-in-git
Possibly https://git-scm.com/docs/git-filter-branch will help.