0
난 gradle 3.5 및 maven 플러그인을 사용하고 있습니다.gradle maven 플러그인을 사용할 때 Java 타겟 및 소스 버전을 설정하는 방법은 무엇입니까?
나는 pom.xml을 생성하는 작업을 가지고 있는데, 생성 된 pom은 java 소스 및 대상 버전으로 인해 잘못되었습니다. 실패
task createPom << {
pom {
project {
groupId 'com.domain.api'
artifactId 'gs-gradle'
version '0.1.0'
inceptionYear '2008'
licenses {
license {
name 'The Apache Software License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
distribution 'repo'
}
}
}
}.writeTo("pom.xml")
}
는 이쪽 gradle makePom
작업을합니다 다음 build
객체를 추가 할 때이 출력 오류가
task createPom << {
pom {
project {
groupId 'com.domain.api'
artifactId 'gs-gradle'
version '0.1.0'
build {
plugins {
plugin {
groupId 'org.apache.maven.plugins'
artifactId 'maven-compiler-plugin'
version '3.7.0'
configuration {
source '1.8'
target '1.8'
}
}
}
}
inceptionYear '2008'
licenses {
license {
name 'The Apache Software License, Version 2.0'
url 'http://www.apache.org/licenses/LICENSE-2.0.txt'
distribution 'repo'
}
}
}
}.writeTo("pom.xml")
}
:
이 1.5 (잘못)에 대한 pom.xml 파일을 생성
시도하고 빌드 할 때 오류 메시지가 표시 되나요? – dave