[p4] Trying to use Perforce via Eclipse

Jeff Jensen jeffjensen at upstairstechnology.com
Wed Oct 12 15:14:40 PDT 2005

Quoting Janine Sisk <janine at furfly.net>:

> On Oct 12, 2005, at 9:39 AM, Jeff Jensen wrote:
> > Sorry, I am not sure on that!  On an empty workspace, I have always
> > populated
> > the files via P4V first, used "File -> Import" to setup the
> > existing Eclipse
> > projects, then setup the plugin on the local project files.  Maybe
> > someone else
> > can answer this one...
> Ok, I tried it your way and it worked better.  The only problem now
> is that when in Java view, there seems to be no recognition that the
> files are under Perforce control.  I opened one, changed it
> (answering yes when asked if I wanted to make it writeable) and saved
> it, without any activity showing in the Perforce view.  Right
> clicking on the file doesn't give me any options to check it out.
> The view of the file in P4V doesn't seem to realize that anything has
> changed, unless I explicitly tell it to diff the last revision
> against the workspace version, and then it shows the line i added.
> So then I went back to the Perforce view, navigated to the same file,
> and chose "open for edit" from the right-click menu.  Now P4V shows
> that I have the file checked out.
> So... am I expecting too much to think that I should be able to check
> out files from the Java view and not have to switch over to the
> Perforce view and navigate to the file each time I want to check one
> out?
> Or is this just the way it's supposed to work?

No, you are not expecting too much.  ;-)

"setup the plugin on the local project files" in my prior response means to Team
-> Share... on each Eclipse project to setup/link it with the source control
system (Perforce).  Sounds like you haven't done that...

It should behave similarly to other Eclipse SCM plugins (I have used Perforce,
CVS, ClearCase, and VSS plugins with Eclipse/WSAD)...for example, open a file
in an Eclipse editor, start typing, and the SCM plugin automatically checks it

(you may know this, but just in case...) To work correctly with files, Perforce
needs to start with the read only bit set to on.  The various Perforce clients
update the read only bit accordingly.  This is opposite to CVS usage, and
usually initially confuses new CVS-experienced Perforce users.

More information about the perforce-user mailing list