开发者

Intellij Grails and Git

I want to backup my code using smart Git. As a start I am a bit confused, IntelliJ has created two folders for my Grails project:

  1. C:\Documents and Settings\me\.grails\1.2.1\projects
  2. C:\Documents and Settings\me\IdeaProject开发者_JS百科s\

#1 contains a plugins folder containing directories and files of plugins I am using inside my project.

The question is: Do I have to include both #1 and #2 directories inside GIT?

If yes, what can I ignore?

If no, which of the files do I have to include?


Stuff under the .grails folder shouldn't be version-controlled. That's where classes are compiled, temp files are created, etc. Also plugins get installed there but typically you don't want to check those in since they're derived.

Another developer who checks out your code will have the plugins listed in application.properties and when running for the first time Grails will detect that they're not installed and install them.

As for your project code, most files that you wouldn't want to check in are now created in the target directory, so that should be in your git ignore but most everything else other than log files should be checked in.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜