git/list[1] front-page[2] threads[3] people[4] search[5] about
 

git-p4: Importing a Git repository into Perforce without rebasing

From
RMRussell Myers <mezner@russellmyers.com>
Date
Feb 19, 2013, 02:40 UTC
Message-ID
<CAA5tD2sZiYcH+edbuO2Uh43zNUOyDYUO_JHpRhrLOjSqV-PfpA@mail.gmail.com>
Hello,

I'm trying to take a Git repository which has never been in Perforce and push it to Perforce and having difficulty.

It would appear that git-p4 requires that a repository is cloned using "git p4 clone" in order to use it to push back to Perforce. That would not be the case here as the repository in question has never been tracked by Perforce.

I know that I could create another Git repository that has some commits in it cloned from Perforce and rebase on top of that; however, the repository I'm trying to import is rather large and rebasing would require me to change many merge commits. I'd like to avoid doing this. The repository has many thousands of commits in it.

In short my question is this: Using git-p4, is there a way to push a Git repository into Perforce without rebasing on top of commits coming from Perforce?

Thanks,
Russell Myers
Next: Thomas Berg
Message 1 of 3 in “git-p4: Importing a Git repository into Perforce without rebasing”
  1. Russell MyersFeb 19, 2013
  2. Thomas BergFeb 19, 2013
  3. Enrico WeigeltMar 4, 2013

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.