Git Product home page Git Product logo

git-p4s's People

Contributors

lm1 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar

Forkers

progician

git-p4s's Issues

Support task streams

Tasks streams differ from other stream types in that they are "sparse". They only contain files that were changed in the stream.

This is also how they appear in git, which is not correct - they should have all the files that existed in the parent at the branch point as well.

If you can give me a summary of the changes that would be required I can implement them. Its not immediately obvious to me how to go about this. It looks like P4Sync.importChange should call filelog on the parent stream with the changelist number of the branch point, but I am not certain.

Exception in git-p4s.py sync

Hi,

I am trying to initialise a repo with a number of streams from our p4 depot.

git-p4s.py sync //spfw/Main //spfw/sp16 //spfw/sp16_rtos //spfw/ppth //spfw/sp17 //spfw/neos_test //spfw/logos-test //spfw/ATBaha

The process gets to about 20% and then it dies with the following error:

  Traceback (most recent call last):
     File "/Users/joseph/etc/bin/git-p4s.py", line 1459, in <module>
        main()
     File "/Users/joseph/etc/bin/git-p4s.py", line 1455, in main
        if not cmd.run():
     File "/Users/joseph/etc/bin/git-p4s.py", line 1414, in run
      self.importChanges(allChanges)
    File "/Users/joseph/etc/bin/git-p4s.py", line 1299, in importChanges
      self.importChange(stream, details)
    File "/Users/joseph/etc/bin/git-p4s.py", line 1274, in importChange
      merges = self.detectMerges(depotpath, change, files, integrates)
    File "/Users/joseph/etc/bin/git-p4s.py", line 1229, in detectMerges
      if self.isMergeFrom(stream, change, srcStream, srcChange):
    File "/Users/joseph/etc/bin/git-p4s.py", line 1194, in isMergeFrom
      if diff[0]["code"] == "error":
  IndexError: list index out of range

In debugging I find that the p4 command raises an EOFError without adding any results (not surprising given the -q flag). When running the p4 command manually I see that every result entry gives "identical".

Consequently, I have worked around the issue (I hope) by adding a condition that returns true if diff is empty:

        if not diff:
            return True

Is this correct?

Actually create branches instead of just sub-folders

I'm trying to use your tool (thank you BTW, very important to my current radar).

I'm trying to bring in the following stream format

mainline (//streamsdepot/main_ProjectA)
|-->release 1.0 (//streamsdepot/rel_ProjectA_1_0)

I do this by going into a blank local git repo folder on my desktop and type the following command

python ..\git-p4s\git-p4s.py sync //streamsdepot/main_ProjectA //streamsdepot/rel_ProjectA_1_0

The import is "successful", however I see the following when I run git branch
`

  • master
    p4/main_ProjectA -> remotes/p4/main_ProjectA
    p4/rel_ProjectA_1_0 -> remotes/p4/rel_ProjectA_1_0
    `

This means that both code "branches" are under the "master" branch. I thought it should find the branch point in perforce, create the branch, fork the code, and then continue on with merges to both branches and not just put code into simple folders in git.

Am I doing something incorrectly here?

Thanks!
Stephen

Feature request: submit to p4

What would be required to achieve this?

Is it possible to get a partial solution by adding the metadata that git-p4 uses so that if you sync using p4s you can subsequently submit to a single stream using git-p4? (NB I saw the readme comment about compatibility, but I'm curious if there is any way to get partial compatibility in order to use their submit functionality)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.