mercredi 14 octobre 2015

When nesting git repos, is it possible to have the parent track the child?

I'm aware of submodules, but am not sure that will serve this use case.

I've got a repo for a library that's meant to be a framework. In order to write tests, I need to embed a fake app inside test/ that uses the framework.

One of the framework's features is parsing .git/HEAD in the app root to make it easy to display a link to the app's current SHA on github. So, I need to initialize a git repo under test/ in order to test that feature.

Ideally, I'd like the parent repo (which lives in /.git) to track the contents of the nested repo (including /test/.git) as if they were just ordinary files.

Aucun commentaire:

Enregistrer un commentaire