views:

44

answers:

1

Well, till now, I used common git operations like push, pull, commit and clone.

But now, I need a git repo with different branches to test certain features but all these features require the same library which should be included in the repo.

What's the best pratice to do this?

+2  A: 

git submodule would be a good practice (more on submodules here).

Reference in your project another repo which contains only your external library.
Each branch can reference the same revision of that library repo.

The idea is to memorize (actually version) the exact dependency you need directly withni your project.

VonC