Is it better to keep Git repository inside or outside of Eclipse workspace?

后端 未结 2 1916
滥情空心
滥情空心 2020-12-02 15:16

I am a typical Eclipse/Subversion user beginning the migration to Git. I\'ve researched the basic concepts of git and have decided to stick to a one project per repository a

2条回答
  •  执念已碎
    2020-12-02 16:06

    The implications of both solutions are listed directly in the user guide that you linked. I can tell you that the part

    This can result in performance issues

    is unfortunately very true. So if you have a git directory with a huge number of files inside your workspace, many git operations will start with a "counting objects..." dialog that blocks your IDE because it scans all files in the workspace. For my current 20000 files this means waiting 10 to 20 seconds for every commit, every switch, ...

    In spare time activities, where I can fortunately use the other alternative (having the git working directory outside the workspace) everything feels much snappier and it is fun to merge and switch.

    So if you go for large projects, consider the git directory outside the workspace as first choice.

提交回复
热议问题