Skip to content
This repository has been archived by the owner on Jan 22, 2022. It is now read-only.

A submodule on branch master breaks builds in other branches #4

Open
nvie opened this issue Aug 6, 2010 · 0 comments
Open

A submodule on branch master breaks builds in other branches #4

nvie opened this issue Aug 6, 2010 · 0 comments

Comments

@nvie
Copy link

nvie commented Aug 6, 2010

The problem

I have the following setup:

  • a branch called "master", that contains a submodule to another project
  • a branch called "develop", that does not contain a submodule reference

If I configure a Hudson job to build/test the "develop" branch, the build breaks, because it cannot do the submodule checkout. Because this happens before switching to the "develop" branch, the build is broken before anything started.

Solution

I assume the output of git ls-tree HEAD is scanned for 160000 references to determine which entries are submodules. The ref HEAD at that point still points to master, I suppose in most cases. Instead of ls-tree'ing HEAD, maybe do it on the specified branch?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant