Re: git-p4 cannot use perforce client created by p4java — "Expected view key View1 missing"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Luke Diamand <luke@xxxxxxxxxxx> writes:

> On Fri, 31 Jan 2020 at 13:43, Ivan Selin <ivan.selin@xxxxxxxxxx> wrote:
>>
>> Yes, that's exactly the way that I've tried it and it worked for me.
>> Can we have that integrated into git-p4? What can I do to make it
>> happen?
>
> A patch would be very welcome!
>
> See Documentation/SubmittingPatches for details, but it's likely
> enough to just make the change, and then use git format-patch and git
> send-email.
>
> Please ensure you add a "Signed-off-by" (git commit -s).

Thanks for helping.  Another area a new person struggles is to
propose a good commit log message.  I'd expect this change to be
explained something like this:

    Subject: git-p4: tighten detection of view names

    The current "git p4" code expects that all keys starting with
    "View" are view names (i.e. "View0", "View1", etc.), but a
    Perforce client created using p4java gets an extra key
    "ViewDepotType", which is not something we want to be treated as
    a view key.

    Tighten the filter of keys to accept only string "View" followed
    by nothing but digits.

    Helped-by: Luke Diamand <luke@xxxxxxxxxxx>
    Signed-off-by: ...

Note that I am not a Perforce person, so the phrase "view names" I
used in the above may totally be wrong as P4-lingo, in which case
please replace them with what is acceptable by our Perforce friends
;-)

Thanks.

>> ...
>> > is_view = re.compile(r'^View\d+$')
>> > view_keys = [ k for k in entry.keys() if is_view.match(k) ]



[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux