Move commonly used methods out to Common_scripts
This commit is contained in:
parent
70b23d7049
commit
ca2db55d2b
2 changed files with 4 additions and 4 deletions
|
|
@ -1,4 +1,4 @@
|
||||||
def githelper = load("Common_scripts/versioncontrol/git.gsh")
|
def gh = load("${WORKSPACE}/Common_scripts/versioncontrol/git.gsh")
|
||||||
|
|
||||||
configurationCollection = [:]
|
configurationCollection = [:]
|
||||||
|
|
||||||
|
|
@ -29,6 +29,6 @@ String getFormattedConfiguration() {
|
||||||
}
|
}
|
||||||
|
|
||||||
def gitCheckoutAndRegister(String tool, String gitURL, String revision, String targetDir, String repoRoot = "", int cloneDepth = 1, boolean shallowClone = true) {
|
def gitCheckoutAndRegister(String tool, String gitURL, String revision, String targetDir, String repoRoot = "", int cloneDepth = 1, boolean shallowClone = true) {
|
||||||
githelper.gitCheckout(gitURL, revision, targetDir, repoRoot, cloneDepth, shallowClone)
|
gh.gitCheckout(gitURL, revision, targetDir, repoRoot, cloneDepth, shallowClone)
|
||||||
registerConfigurationInfo(tool, gitURL, revision, getGitInfo(targetDir))
|
registerConfigurationInfo(tool, gitURL, revision, getGitInfo(targetDir))
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,8 +1,8 @@
|
||||||
def commandlinehelper = load("Common_scripts/commandline/commandline.gsh")
|
def clh = load("${WORKSPACE}/Common_scripts/commandline/commandline.gsh")
|
||||||
|
|
||||||
String getGitInfo(String workingSetRootPath) {
|
String getGitInfo(String workingSetRootPath) {
|
||||||
dir(workingSetRootPath) {
|
dir(workingSetRootPath) {
|
||||||
return commandlinehelper.getCommandOutput('git log -1 --format=oneline')
|
return clh.getCommandOutput('git log -1 --format=oneline')
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue