Created
May 29, 2019 17:15
-
-
Save kmcquade/e530fc733d3a6a6ae1150e1b65f7a05e to your computer and use it in GitHub Desktop.
List pending script approvals in Jenkins
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import org.jenkinsci.plugins.scriptsecurity.scripts.* | |
ScriptApproval sa = ScriptApproval.get(); | |
//list pending approvals | |
for (ScriptApproval.PendingScript pending : sa.getPendingScripts()) { | |
println "Pending Approved : " + pending.script | |
} | |
//list pending signatures | |
for (ScriptApproval.PendingSignature pending : sa.getPendingSignatures()) { | |
println "Pending Signature : " + pending.signature | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment