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
#!/bin/bash | |
set -e | |
UPDATES_URL="http://updates.jenkins-ci.org/download/plugins/" | |
if [ $# -lt 2 ]; then | |
echo "USAGE: $0 plugin-list-file destination-directory" | |
exit 1 | |
fi |
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
/*** BEGIN META { | |
"name" : "Count executors", | |
"comment" : "Shows the total number of nodes and executors on Jenkins", | |
"parameters" : [ ], | |
"core": "1.350", | |
"authors" : [ | |
{ name : "Andy Pemberton" } | |
] | |
} END META**/ | |
import jenkins.model.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
#!groovy | |
# Best of Jenkinsfile | |
# `Jenkinsfile` is a groovy script DSL for defining CI/CD workflows for Jenkins | |
node { | |
} |
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 hudson.model.* | |
def payloadString = build.buildVariableResolver.resolve("payload") | |
payloadObject = new groovy.json.JsonSlurper().parseText(payloadString) | |
targetCommit = payloadObject.pull_request.head.sha | |
build.addAction(new ParametersAction(new StringParameterValue('targetCommit', targetCommit))) |