I am using EGit in eclipse to provide Git support for an Android project I am working on. The problem is that after committing my project to the local repository I realized that the "gen" folder was not getting committed. As a result of this when I try to open the project on another machine after getting the latest source from the Git repository I keep getting the following error:
ERROR: Unable to open class file D:\CodeRep\POCs\Java\Android\Sudoku\gen\org\blah\example\R.java: No such file or directory
Why can't I commit the "gen" folder to Git from Eclipse ? Everything gets committed just fine so I can push it to the remote repository.
You shouldn't be commiting the gen
folder; it contains generated code and doesn't belong in source control. You should be recreating it on the machine you pull the source code on with either an Eclipse "Project -> Clean" or a command line "ant clean
" if you're using the build scripts.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With