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

Re: git-p4: commits are visible in history after 'git p4 clone', but not a single file present

From
IDIlya Dogolazky <ilya.dogolazky@nokia.com>
Date
Jun 13, 2012, 06:58 UTC
Message-ID
<4FD83A08.6070208@nokia.com>
In-Reply-To
<20120612222431.GA13427@padd.com>
Hi Pete !
06/13/2012 01:24 AM, ext Pete Wyckoff написал:
> Fascinating.  So //kalma/xxx/yyy is a depot hosted in a p4d that runs
> on your local box, but //xxx/yyy is the depot name hosted in
> the company's p4d?

No. But now I think I understand, what I did wrong. There is no p4d running on my own machine. "kalma" in this case is the name of the so called "perforce client" I tried to use. And I think my error was to express "please use perforce client 'kalma' to access depot '//xxx/yyy'" by the string "//kalma/xxx/yyy", which is wrong. I'm pretty sure it was not quite my own idea to do so, probably I misunderstood some piece of documentation somewhere.

> I'm completely confused that //kalma/xxx/yyy even appeard to work
> at all.  Will be interested to see your P4PORT setting when using
> that repo.

And I think I understand now, why "//kalma/xxx/yyy" appeared to work: it took all the commits, but as I wanted to have something beginning with "kalma" I got no files, because everything begins with "xxx" (and couple of other names, none of them is equal to 'kalma'). Does this explanation seem reasonable?

> Ooh.  You're using the shiny new "streams" feature in p4,
> I think.  Can you play with "p4 stream" to see if one is
> defined on //xxx or //xxx/yyy?.

Yes, alas I have to use it. Now I re-defined my "client" settings, included the stream there and started from the beginning. Here is what I did:

$ p4 client (and edit opened file .....) Client xexe1 saved. $ P4CLIENT=xexe1 p4 sync //xxx/yyy/zzz/readme.txt#1 - added as /x/data/tmp/xexe/yyy/zzz/readme.txt $ P4CLIENT=xexe1 git p4 clone //xxx/yyy@all ~/xexe1 Importing from //xxx/yyy into /home/ilya/xexe1 Initialized empty Git repository in /home/ilya/xexe1/.git/ Doing initial import of //xxx/yyy/ from revision #head into refs/remotes/p4/master $ cd ~/xexe1 $ vim zzz/readme.txt (and edit it) $ git commit zzz/readme.txt

Until now everything worked fine, so now is time to submit the changes on readme.txt file ("rebase" is not needed, as no changes happened yet since I cloned).

$ P4CLIENT=xexe1 git p4 submit
Error: Cannot locate perforce checkout of //xxx/yyy/ in client view

This message comes from git-p4 script somewhere around line 1276 and I don't understand its meaning.

Then I tried to set git-p4.useclientspec to "true" and I got the message: $ P4CLIENT=xexe1 git p4 submit Can't handle %n wildcards in view: //xxx/yyy/zzz/somefile%%1

This "%%1" is visible in client config (as opened in editor during execution "P4CLIENT=xexe1 p4 client"), but I have not added it by myself: this line [and many other similar lines in View: section] was added after I set "Stream: //xxx/yyy" there. The beginning of View: section looks like this now:

//xxx/yyy/zzz/... //xexe1/zzz/... -//xxx/yyy/zzz/somefile%%1 //xexe1/zzz/somefile%%1

(yes, it begins with '-' and there are many other lines beginning with '-', but this one is the only one containing '%%')

What do you think, is it now something wrong with git-p4 or is it again something wrong in my setup?

Cheers,
Ilya
Previous: Pete WyckoffNext: Ilya Dogolazky
Message 7 of 10 in “git-p4: commits are visible in history after 'git p4 clone', but not a single file present”
  1. Ilya DogolazkyJun 11, 2012
  2. Luke DiamandJun 11, 2012
  3. Ilya DogolazkyJun 11, 2012
  4. Luke DiamandJun 11, 2012
  5. Ilya DogolazkyJun 12, 2012
  6. Pete WyckoffJun 12, 2012
  7. Ilya DogolazkyJun 13, 2012
  8. Ilya DogolazkyJun 13, 2012
  9. Luke DiamandJun 13, 2012
  10. Ilya DogolazkyJun 14, 2012

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.