Dori
Dori

Reputation: 18413

Version control and Android Library Projects

When using Android Library Project does anyone have a good solution for version control for projects that utilise these librarys?

For example if I have two apps, say a free version and paid, or phone and tablet, or any other scenario, and i want them to use some shared library's which are contained in an Android Lib Project, how can i safely add these projects to SVN? As they are seperate projects I have no way i know off enforcing that when one is committed the other (library one) is also.

I am using Eclipse with the Subclipse SVN plugin, does anyone know if there is a way to link the projects so a commit on one will commit the other?

Any tips here would be welcome - as I am relatively new to SVN - so may be thinking about this in the wrong way :)

Thanks

Upvotes: 5

Views: 1348

Answers (2)

Timo Ohr
Timo Ohr

Reputation: 7947

You cannot enforce that both are committed at the same time (that's just not how SVN works), but you can still do it (by, as bigstones said, using Ctrl+Click or putting both of them in a Working Set, and committing that).

The way Android handles libraries is indeed quite flawed, and this is one of the reasons for it.

Upvotes: 5

bigstones
bigstones

Reputation: 15267

I'm quite new to versioning too, I'm using Subclipse too, I don't know if there's a way to commit both project and lib at once (if not selecting both with ctrl-click), but actually the "modified" icon is pretty visible and I never forgot about it.

The problem for me is that sometimes I modify the source opening it from the lib project, sometimes opening the source referenced in the app project, and I must remember to refresh the other. In case I forget it, in the second case, the lib project won't show the "modified" icon, so I end up refreshing both projects very often.

Upvotes: 1

Related Questions