0

The unity3d jenkins plugin https://plugins.jenkins.io/unity3d-plugin/#documentation is quite old. It hasn't been updated since 2015! I'd like to use it in a pipeline script, but the documentation doesn't say what the pipeline syntax is.

I'm not a jenkins plugin author pro, but there's a @DataBoundConstructor here https://github.com/jenkinsci/unity3d-plugin/blob/master/src/main/java/org/jenkinsci/plugins/unity3d/Unity3dBuilder.java#L53 that looks promising, but the following doesn't work:

Unity3DBuilder: unity3dName: "Unity 2019.4.5", argLine: "-quit -batchmode -projectPath . -logFile ${WORKSPACE}\compilelog.txt"

The error says unexpected token: unity3dName.

EDIT: I tried this alternative syntax and also got an error:

Unity3dBuilder(unity3dName: "Unity 2019.4.5", argLine: "-quit -batchmode -projectPath . -logFile ${WORKSPACE}\\compilelog.txt")

With the error: No such DSL method 'Unity3dBuilder'

Am I right in assuming that any old plugin can be used from a pipeline script? And if so, what would be the correct syntax for this one?

1 Answer 1

1

Plugins are not inherently pipeline compatible.

Light reading: Refactoring a Jenkins plugin for compatibility with Pipeline jobs

Writing Pipeline-Compatible Plugins

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .