I have a super project that only aggregates multiple git sumodules. I would like to trigger Jenkins for each change in submodules as well as when super project is updated.
/superproject
/submodule-a
/submodule-b
/submodule-c
For each submodule I am using Job DSL plugin and works fine except when some modules require others to compile or run tests -- that is one reason to aggregate all other repos in one super project.
What should I do for testing individual submodules as well as integration as part of a super project?
I think this does not make sense. If git plugin is configured to trigger a job after post-receive
hook in remote
repository then it should work.
If a new commit is pushed to a submodule the parent project does not noticies. You must have to do:
git submodule update --remote --recursive
git commit
git push
Then, and only then, the job should receive the notification. For more information you could read:
来源:https://stackoverflow.com/questions/31214483/trigger-jenkins-tests-after-commits-in-git-submodules