16 lines
483 B
Groovy
16 lines
483 B
Groovy
import jenkins.model.Jenkins
|
|
import org.codefirst.SimpleThemeDecorator
|
|
|
|
def instance = Jenkins.get()
|
|
def decorators = instance.getExtensionList(SimpleThemeDecorator.class)
|
|
|
|
if (decorators?.size() > 0) {
|
|
def theme = decorators[0]
|
|
theme.setCssUrl("https://ci.bstein.dev/userContent/jenkins-theme.css")
|
|
theme.setJsUrl("")
|
|
instance.save()
|
|
println("Applied simple-theme-plugin dark theme")
|
|
} else {
|
|
println("simple-theme-plugin not installed; skipping theme configuration")
|
|
}
|