4

My firm is moving from PVCS to Git and I would like to know how can it help with the issues..

The current process is

  • We check everything out of PVCS
  • We then open Eclipse and Import the files in
  • We then have to fix the .classpath and profile file due to all the stuff not having jars in same place
  • Lock File in PVCS
  • Make Changes in Eclipse
  • Copy File from Eclipse workspace to PVCS folder
  • Unlock File

--- That was the current process, very long and room for error

What I would like to move everything to git and just do a git pull but I dont want the .classpath and project file issue like I have in PVCS all the time.. I am thinking can I tell git to only read the .classpath and project file and never update it?

I would love to hear how old eclipse using are working with git and ant.. thanks

1 Answer 1

6

You should put the .classpath file in .gitignore so that it never enters git in the first place.
This way, each developer will have a purely local copy.

To manage your dependencies, you should use Maven; its pom.xml is machine-independent and can live in git, and Eclipse can generate everything else from that file.

4
  • can we use maven and ant?
    – JMSAZ2013
    Oct 29, 2013 at 15:03
  • @JMSAZ2013: Yes, but you should consider using Maven to replace Ant.
    – SLaks
    Oct 29, 2013 at 15:46
  • the issue is that the firms ant scr is very big
    – JMSAZ2013
    Oct 29, 2013 at 17:43
  • I am working with a multi-module project. Adding .classpath and .project to .gitignore is only ignoring the instance in the root directory, but the sub-folders containing .classpath and .project are still showing up as changes. I tried adding **/.classpath to .gitignore but that does not appear to work.
    – Web User
    May 3, 2017 at 20:56

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.