Question

Periodically, when I'm doing git p4 submit, I get a nasty error:

Could not determine file type for rails_project/public/favicon.ico 
(result: '//mydepot/main/rails_project/public/favicon.ico#1 - add 
default change (binary+l) *exclusive*')

In each case, it's some odd binary-type file that confuses the thing (like the favicon.ico above), or (most often) a graphic, like a PNG. And this kills the submit and leaves all the files that were opened before it in an opened state, but not yet submitted...

Resolving this ends up being a pain in the ass, where I end up having to use p4v to go in and manually submit half of what I was trying to submit via a new changelist, and then finish my submit (crossing my fingers that I don't hit another weird file and get stuck again).

(this is on git version 1.8.3.2 on a Mac with OS X Mountain Lion)

Has anyone come up with a way to make git p4 behave properly? Any ideas?

Était-ce utile?

La solution

Looking at https://github.com/ermshiperete/git-p4/blob/master/git-p4 for "Could not determine file type for " the regex 're.match(".*\((.+)\)\r?$", result)' isn't matching against '//mydepot/main/rails_project/public/favicon.ico#1 - add default change (binary+l) *exclusive*'.

I guess "*exclusive*" is new from perforce. or at least the git-p4 developer(s) haven't encountered it.

The easiest solution is probably to teach git-p4 about the new perforce syntax, and submit a patch.

EDIT:

Thinking about it - you probably don't want to use git-p4 for any files you (or your company) have decided should have exclusive locks, since git will break the exclusiveness of the locks.

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top