author | Vitor Antunes <vitor.hda@gmail.com> | |
Thu, 18 Aug 2011 23:44:03 +0000 (00:44 +0100) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Tue, 23 Aug 2011 04:08:37 +0000 (21:08 -0700) | ||
commit | 04d277b39e3e40f939fd7935c30beb48452015ec | |
tree | 525ec022ea6c5a82818d04a9bec49a44a46bb73e | tree | snapshot |
parent | 68cbcf1b2575ca151ed3b11698916bcbbd1b890c | commit | diff |
git-p4: Correct branch base depot path detection
When branch detection is enabled each branch is named in git after their
relative depot path in Perforce. To do this the depot paths are compared against
each other to find their common base path. The current algorithm makes this
comparison on a character by character basis.
Assuming we have the following branches:
//depot/branches/featureA
//depot/branches/featureB
Then the base depot path would be //depot/branches/feature, which is an invalid
depot path.
The current patch fixes this by splitting the path into a list and comparing the
list entries, making it choose correctly //depot/branches as the base path.
Signed-off-by: Vitor Antunes <vitor.hda@gmail.com>
Acked-by: Pete Wyckoff <pw@padd.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
When branch detection is enabled each branch is named in git after their
relative depot path in Perforce. To do this the depot paths are compared against
each other to find their common base path. The current algorithm makes this
comparison on a character by character basis.
Assuming we have the following branches:
//depot/branches/featureA
//depot/branches/featureB
Then the base depot path would be //depot/branches/feature, which is an invalid
depot path.
The current patch fixes this by splitting the path into a list and comparing the
list entries, making it choose correctly //depot/branches as the base path.
Signed-off-by: Vitor Antunes <vitor.hda@gmail.com>
Acked-by: Pete Wyckoff <pw@padd.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
contrib/fast-import/git-p4 | diff | blob | history |