Skip to content

Commit

Permalink
замена . на WORKSPACE
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanovEV committed Mar 14, 2024
1 parent 93af3ff commit 626333a
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ru/pulsar/jenkins/library/steps/GetExtensions.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class GetExtensions implements Serializable {
String srcDir = getSrcDir(it, sourceDirName)
buildExtension(it, srcDir, vrunnerPath, steps)
} else if (it.initMethod == InitExtensionMethod.FILE){
Logger.println("Загрузка расширения ${it.name} из интернета по ссылке ${it.path}")
Logger.println("Загрузка расширения ${it.name} из ${it.path}")
loadExtension(it, env)
} else {
Logger.println("Неизвестный метод инициализации расширения ${it.name}")
Expand Down Expand Up @@ -77,7 +77,8 @@ class GetExtensions implements Serializable {
localPathToExtension.copyFrom(new URL(extension.path))
} else {
// If the path is a local file, copy the file
FilePath localFilePath = FileUtils.getFilePath(extension.path)
String localPath = extension.path.startsWith(".") ? "$env.WORKSPACE/${extension.path.substring(1)}" : extension.path
FilePath localFilePath = FileUtils.getFilePath(localPath)
localPathToExtension.copyFrom(localFilePath.toURI().toURL())
}
}
Expand Down

0 comments on commit 626333a

Please sign in to comment.