Compare commits

...

5 commits

Author SHA1 Message Date
forozco
c6da6ac98d bump gradle 2020-07-22 10:15:02 -04:00
Felipe Orozco
b0d3fd8d05 Add generated changelog entries 2020-07-22 14:09:19 +00:00
Felipe Orozco
19faa84f08
Update build.gradle 2020-07-22 10:09:19 -04:00
Felipe Orozco
2eba367b12
Update and rename bintray-publish.gradle to publish-jar.gradle 2020-07-22 10:08:31 -04:00
Felipe Orozco
daf65397c8
Update build.gradle 2020-07-22 10:05:01 -04:00
8 changed files with 84 additions and 58 deletions

View file

@ -45,15 +45,12 @@ apply plugin: 'com.gradle.plugin-publish'
apply plugin: 'com.palantir.baseline'
apply plugin: 'com.palantir.git-version'
apply plugin: 'com.palantir.consistent-versions'
apply plugin: 'nebula.maven-publish'
apply plugin: 'nebula.source-jar'
apply plugin: 'org.inferred.processors'
apply plugin: 'java-gradle-plugin'
apply plugin: 'groovy'
apply plugin: 'eclipse'
apply plugin: 'idea'
apply plugin: 'com.palantir.java-format'
apply from: "${rootDir}/gradle/bintray-publish.gradle"
apply from: "${rootDir}/gradle/publish-jar.gradle"
group 'com.palantir.graal'
version gitVersion()
@ -93,6 +90,10 @@ pluginBundle {
}
}
publishPlugins.onlyIf {
project.version ==~ /[0-9]+(\.[0-9]+)+(-rc[0-9]+)?(-alpha[0-9]+)?/
}
tasks.withType(JavaCompile).configureEach {
options.errorprone.errorproneArgs += [
'-Xep:PreferSafeLoggableExceptions:OFF',

View file

@ -0,0 +1,5 @@
type: improvement
improvement:
description: Only publish releases to gradle
links:
- https://github.com/palantir/gradle-graal/pull/371

View file

@ -1,36 +0,0 @@
/*
* (c) Copyright 2018 Palantir Technologies Inc. All rights reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
apply plugin: 'com.jfrog.bintray'
bintray {
user = System.env.BINTRAY_USERNAME
key = System.env.BINTRAY_PASSWORD
publish = true
pkg {
repo = 'releases'
name = rootProject.name
userOrg = 'palantir'
licenses = ['Apache-2.0']
publications = ['nebula']
}
}
publish.dependsOn bintrayUpload
bintrayUpload.onlyIf {
versionDetails().isCleanTag
}

55
gradle/publish-jar.gradle Normal file
View file

@ -0,0 +1,55 @@
// This file is managed by the excavator 'consistent-publish-scripts' check, changes will be overwritten.
apply plugin: 'com.jfrog.bintray'
// Intentionally not applying nebula.maven-publish, but most of its constituent plugins,
// because we do _not_ want nebula.maven-compile-only
apply plugin: 'maven-publish'
apply plugin: 'nebula.maven-nebula-publish'
apply plugin: 'nebula.maven-base-publish'
apply plugin: 'nebula.maven-developer'
apply plugin: 'nebula.maven-manifest'
apply plugin: 'nebula.info-scm'
apply plugin: 'nebula.maven-scm'
apply plugin: 'nebula.javadoc-jar'
apply plugin: 'nebula.source-jar'
jar {
manifest {
attributes("Implementation-Version" : project.version)
}
}
bintray {
user = System.env.BINTRAY_USERNAME
key = System.env.BINTRAY_PASSWORD
publish = true
pkg {
repo = 'releases'
name = 'gradle-graal'
userOrg = 'palantir'
licenses = ['Apache-2.0']
publications = ['nebula']
}
}
publish.dependsOn bintrayUpload
bintrayUpload.onlyIf {
versionDetails().isCleanTag
}
// See: https://docs.gradle.org/5.2/userguide/publishing_maven.html#publishing_maven:resolved_dependencies
// This replaces nebula.maven-resolved-dependencies, which doesn't work with the 'com.gradle.plugin-publish' plugin
publishing {
publications.withType(MavenPublication).configureEach {
versionMapping {
allVariants {
fromResolutionResult()
}
}
}
}
// Turning off module metadata so that all consumers just use regular POMs
tasks.withType(GenerateModuleMetadata) {
enabled = false
}

Binary file not shown.

View file

@ -1,5 +1,5 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-6.5.1-bin.zip
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists

31
gradlew vendored
View file

@ -82,6 +82,7 @@ esac
CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar
# Determine the Java command to use to start the JVM.
if [ -n "$JAVA_HOME" ] ; then
if [ -x "$JAVA_HOME/jre/sh/java" ] ; then
@ -129,6 +130,7 @@ fi
if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
APP_HOME=`cygpath --path --mixed "$APP_HOME"`
CLASSPATH=`cygpath --path --mixed "$CLASSPATH"`
JAVACMD=`cygpath --unix "$JAVACMD"`
# We build the pattern for arguments to be converted via cygpath
@ -154,19 +156,19 @@ if [ "$cygwin" = "true" -o "$msys" = "true" ] ; then
else
eval `echo args$i`="\"$arg\""
fi
i=$((i+1))
i=`expr $i + 1`
done
case $i in
(0) set -- ;;
(1) set -- "$args0" ;;
(2) set -- "$args0" "$args1" ;;
(3) set -- "$args0" "$args1" "$args2" ;;
(4) set -- "$args0" "$args1" "$args2" "$args3" ;;
(5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
(6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
(7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
(8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
(9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
0) set -- ;;
1) set -- "$args0" ;;
2) set -- "$args0" "$args1" ;;
3) set -- "$args0" "$args1" "$args2" ;;
4) set -- "$args0" "$args1" "$args2" "$args3" ;;
5) set -- "$args0" "$args1" "$args2" "$args3" "$args4" ;;
6) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" ;;
7) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" ;;
8) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" ;;
9) set -- "$args0" "$args1" "$args2" "$args3" "$args4" "$args5" "$args6" "$args7" "$args8" ;;
esac
fi
@ -175,14 +177,9 @@ save () {
for i do printf %s\\n "$i" | sed "s/'/'\\\\''/g;1s/^/'/;\$s/\$/' \\\\/" ; done
echo " "
}
APP_ARGS=$(save "$@")
APP_ARGS=`save "$@"`
# Collect all arguments for the java command, following the shell quoting and substitution rules
eval set -- $DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS "\"-Dorg.gradle.appname=$APP_BASE_NAME\"" -classpath "\"$CLASSPATH\"" org.gradle.wrapper.GradleWrapperMain "$APP_ARGS"
# by default we should be in the correct project dir, but when run from Finder on Mac, the cwd is wrong
if [ "$(uname)" = "Darwin" ] && [ "$HOME" = "$PWD" ]; then
cd "$(dirname "$0")"
fi
exec "$JAVACMD" "$@"

4
gradlew.bat vendored
View file

@ -29,6 +29,9 @@ if "%DIRNAME%" == "" set DIRNAME=.
set APP_BASE_NAME=%~n0
set APP_HOME=%DIRNAME%
@rem Resolve any "." and ".." in APP_HOME to make it shorter.
for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi
@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script.
set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m"
@ -81,6 +84,7 @@ set CMD_LINE_ARGS=%*
set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar
@rem Execute Gradle
"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %CMD_LINE_ARGS%