nebula-plugins / gradle-ospackage-plugin

Gradle plugin for constructing linux packages, specifically RPM and DEBs.
Apache License 2.0
371 stars 129 forks source link

The OS property cannot be set #384

Open deian-bit opened 4 years ago

deian-bit commented 4 years ago

Initializing the plugin ospackage with the following code is not working :

import com.netflix.gradle.plugins.rpm.Rpm

plugins { id("nebula.ospackage") version "8.4.1" }

ospackage { version = "1.0.0" release = "1" os = LINUX }

The following error during "gradle build" is displayed:

Script compilation error: Line 12: os = LINUX ^ Unresolved reference: LINUX

Setting properties directly in the task has the same result:

tasks.withType {

version = "1.0.0"
release = "1"
packageName = "rest-server"
summary = "rpm for war deployment"
preInstall("scripts/rpm/preInstall.sh")
archStr = "X86_64"
//type = BINARY
os = LINUX

}

By the way there is the same problem with the property "type".

gradle -v

Gradle 6.7-rc-1

Hendrik-H commented 3 years ago

did you try os = org.redline_rpm.header.Os.LINUX ? that works for me just fine in an Rpm task.