Skip to content

Instantly share code, notes, and snippets.

@abayer
Last active August 4, 2017 15:17
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save abayer/79700ea922e523d2e82a28675b1181e6 to your computer and use it in GitHub Desktop.
Save abayer/79700ea922e523d2e82a28675b1181e6 to your computer and use it in GitHub Desktop.
import jenkins.triggers.ReverseBuildTrigger
Jenkins.instance.getAllItems().each { i ->
if (i instanceof Job) {
ReverseBuildTrigger t = i.getTriggers().values().find { it instanceof ReverseBuildTrigger }
if (t != null && t.upstreamProjects == null) {
println "${i.getFullName()} has null upstreamProjects"
}
}
}
return
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment