1

I'm new to bitbucket (free git instead of GitHub), working with it for few days (with SourceTree client).

I'm working on a project with one more friend, and we share the whole eclipse project directory through the repository.

At the beginning it went pretty well, but now problems started to pop up.

For example, when my friend pulled new updates (without conflicts), his project suddenly became a real mess. Nothing compiled, the eclipse couldn't find libraries, and once that was fixed eclipse couldn't find some classes (of this libraries, such as ActionBar and more classes of support library and app compat), and later even there was a problem with the resources of the project (eclipse couldn't find R.java ...).

I guess it was a bad idea to share the whole project in the repository.

So what I'm basically asking is, how to work correctly with eclipse projects? What do I need to share and what to ignore? Couldn't find any examples on the internet so I came here.

Thanks ahead.

2
  • just share the actual project. You can all store lib projects in each of your computers. When someone checkout the project just needs to add lib projects to actual project Commented Sep 24, 2014 at 0:01
  • @santalu as I said, this causes many problems... Commented Sep 24, 2014 at 8:06

2 Answers 2

3

My suggestion is only share the code, use this ignore file.

# built application files
*.apk
*.ap_
*.jar

# files for the dex VM
*.dex

# Java class files
*.class

# generated files
bin/
gen/
build/

# Local configuration file (sdk path, etc)
local.properties

# Eclipse project files
.classpath
.project
/.settings

# Proguard folder generated by Eclipse
proguard/

# Intellij project files
*.iml
*.ipr
*.iws
.idea/

lint.xml

save it as .gitignore in your project directory. And learn a little about ignore file.

Sign up to request clarification or add additional context in comments.

Comments

2

In addition to zz-m's answer, Github has a greate collection of .gitignore files, for a lot of different programming languages, tools, frameworks, IDEs, and many more. It's definitely worth it to keep a bookmark of the page for any upcoming projects you might have.

https://github.com/github/gitignore

Comments

Your Answer

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

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.