cancel
Showing results for 
Search instead for 
Did you mean: 

Config p4 plugin on Mac

dex
Not applicable

Config p4 plugin on Mac

I have recently installed the collaborate client 7.0 on a Mac.  However, the p4 plugin doesn't work.  In particular, when I try to add a change list to review, it says "No SCM Configuration could be determined  reason: cannot run program p4".   Here is the error log.



!ENTRY com.smartbear.collaborator.ui 4 0 2012-03-29 10:52:00.484

!MESSAGE No SCM Configuration could be determined

!STACK 0

com.smartbear.scm.ScmConfigurationException: Cannot run program "p4" (in directory "/Applications/ccollab_client"): error=2, No such file or directory

    at com.smartbear.scm.impl.newp4.P4System.getClientConfiguration(P4System.java:108)

    at com.smartbear.scm.impl.newp4.P4System.getClientConfiguration(P4System.java:80)

    at com.smartbear.scm.impl.perforce.PerforceSystem.getClientConfiguration(PerforceSystem.java:118)

    at com.smartbear.scm.ScmUtils.requireScm(ScmUtils.java:552)

    at com.smartbear.collaborator.ui.standalone.wizards.StandaloneScmConfigAddToReviewWizard$2.run(StandaloneScmConfigAddToReviewWizard.java:149)

    at com.smartbear.collaborator.ui.wizards.ProgressWizardDialog$AsyncWorkerThread.run(ProgressWizardDialog.java:247)

Caused by: com.smartbear.cmdline.ScmCommunicationException: Cannot run program "p4" (in directory "/Applications/ccollab_client"): error=2, No such file or directory

    at com.smartbear.scm.impl.newp4.scmcli.ScmCmdRunner.run(ScmCmdRunner.java:33)

    at com.smartbear.scm.impl.newp4.cli.P4CliConn.executeTextCmd(P4CliConn.java:105)

    at com.smartbear.scm.impl.newp4.cli.P4CliConn.<init>(P4CliConn.java:69)

    at com.smartbear.scm.impl.newp4.P4System.getClientConfiguration(P4System.java:93)

    ... 5 more

Caused by: java.io.IOException: Cannot run program "p4" (in directory "/Applications/ccollab_client"): error=2, No such file or directory

    at java.lang.ProcessBuilder.start(ProcessBuilder.java:460)

    at com.smartbear.scm.impl.newp4.newcli.CommandRunner.run(CommandRunner.java:65)

    at com.smartbear.scm.impl.newp4.newcli.AutoDebugCommandRunner.run(AutoDebugCommandRunner.java:30)

    at com.smartbear.scm.impl.newp4.scmcli.ScmCmdRunner.run(ScmCmdRunner.java:28)

    ... 8 more

Caused by: java.io.IOException: error=2, No such file or directory

    at java.lang.UNIXProcess.forkAndExec(Native Method)

    at java.lang.UNIXProcess.<init>(UNIXProcess.java:53)

    at java.lang.ProcessImpl.start(ProcessImpl.java:91)

    at java.lang.ProcessBuilder.start(ProcessBuilder.java:453)

    ... 11 more



However, p4 is in my PATH variable in the shell.   What do I miss in the configuration?  BTW,  I am able to run the gui app to upload changelist. 



Thanks!
7 REPLIES 7
Not applicable

RE: Config p4 plugin on Mac

I am having the same error.  The p4 file does exist in that directory.  The p4 file has all the correct ownership and permissions.  I also can add changelists through the ccollab client, but not through the p4V - code collaborator plugin.
Not applicable

RE: Config p4 plugin on Mac

Same here.  Any ideas on how to resolve this?
Not applicable

RE: Config p4 plugin on Mac

It appears that we do not actually use the p4 path set in the configuration screen because we instead pull that information from p4v to decide where to connect. You can add the "--p4 <executable path>" option to the p4v custom tool arguments (Tools > Manage Custom Tools > Edit) to get around the path issue and just point directly to the executable. Here is the documentation on global options, in the p4 section:



http://codecollaborator.smartbear.com/docs/manual/7.0/index.html?cmdline_global_options.html
Not applicable

RE: Config p4 plugin on Mac

I don't see how adding a --p4 argument helps in my case. I'm running the CollabTray, there's no way to configure it to tell it the p4 path.



Update. Linking /usr/local/bin/p4 to /usr/bin/p4 solved *that* problem. However now I'm getting an error because it's not using the right user. Which means I'll need to set up global environment variables to tell it the correct username and workspace. Not worth the hassle. Easier to just give up on the tray.
Not applicable

RE: [CodeReviewer] Config p4 plugin on Mac

I am facing the same issue while configuring the ccolllabgui with perforce. Any help will be appreciated.



I am version 7.2.7218



Not able to configure perforce in Code Collaborator at all. Help
Not applicable

RE: [CodeReviewer] Config p4 plugin on Mac

Have you added to p4 to /usr/bin/ and made it executable?



sudo cp <path to file>/p4 /usr/bin/

sudo chmod +x /usr/bin/p4
Zim
New Contributor

Re: RE: Config p4 plugin on Mac

Adding "--p4 <executable path>" resulted in no change.

 

Additionally, it is not possible to add anything to /usr/bin, even with sudo, since Apple implemented the system integrity features. Although this can be worked around, it's bad form, bad security, and bad behavior for non-OS installs to expect access to /usr/bin and clearly not supported.

New Here?
Join us and watch the welcome video:
Watch the new Interview