Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix JitPack build #678

Merged
merged 1 commit into from Oct 9, 2022
Merged

Fix JitPack build #678

merged 1 commit into from Oct 9, 2022

Conversation

beatngu13
Copy link
Member

@beatngu13 beatngu13 commented Oct 8, 2022

Closes #677.

Proposed commit message:

Fix JitPack build (#677 / #678)

From the
[JitPack docs](https://jitpack.io/docs/BUILDING/#java-version):

>JitPack will compile projects using OpenJDK Java 8. See the example
>projects on how to set a different target version in your build file.
>
>Maven projects that specify a target version in their pom will be
>built with that target version.
>
>If your project uses Travis or Circle CI then JitPack will read the
>lowest jdk version from yml file and use that to build.
>
>Alternatively create a jitpack.yml file in the root of your
>repository and specify a jdk version:

This PR adds a `jitpack.yml`, specifying OpenJDK 11 to be used.

Closes: #677
PR: #678

PR checklist

The following checklist shall help the PR's author, the reviewers and maintainers to ensure the quality of this project.
It is based on our contributors guidelines, especially the "writing code" section.
It shall help to check for completion of the listed points.
If a point does not apply to the given PR's changes, the corresponding entry can be simply marked as done.

Documentation (general)

  • There is documentation (Javadoc and site documentation; added or updated)
  • There is implementation information to describe why a non-obvious source code / solution got implemented
  • Site documentation has its own .adoc file in the docs folder, e.g. docs/report-entries.adoc
  • Site documentation in .adoc file references demo in src/demo/java instead of containing code blocks as text
  • Only one sentence per line (especially in .adoc files)
  • Javadoc uses formal style, while sites documentation may use informal style

Documentation (new extension)

  • The docs/docs-nav.yml navigation has an entry for the new extension
  • The package-info.java contains information about the new extension

Code

  • Code adheres to code style, naming conventions etc.
  • Successful tests cover all changes
  • There are checks which validate correct / false usage / configuration of a functionality and there are tests to verify those checks
  • Tests use AssertJ or our own PioneerAssert (which are based on AssertJ)

Contributing

  • A prepared commit message exists
  • The list of contributions inside README.md mentions the new contribution (real name optional)

@beatngu13 beatngu13 requested a review from Bukama October 8, 2022 17:55
@beatngu13 beatngu13 marked this pull request as ready for review October 8, 2022 17:55
@beatngu13
Copy link
Member Author

JitPack build is now successful:

Build starting...
Start: Sat Oct 8 17:56:38 UTC 2022 0f40de50a814
Git:
v1.7.1-15-gb5b6319
commit b5b63199ac9d5d937421fff7f45c6cd8ea89ca1b
Author: Daniel Kraus 
Date:   Sat Oct 8 19:49:27 2022 +0200

    Add jitpack.yml


Init SDKMan
Found gradle
Gradle build script
Found gradle version: 7.5.
Using gradle wrapper
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
Downloading https://services.gradle.org/distributions/gradle-7.5-bin.zip
.10%.20%.30%.40%.50%.60%.70%.80%.90%.100%

------------------------------------------------------------
Gradle 7.5
------------------------------------------------------------

Build time:   2022-07-14 12:48:15 UTC
Revision:     c7db7b958189ad2b0c1472b6fe663e6d654a5103

Kotlin:       1.6.21
Groovy:       3.0.10
Ant:          Apache Ant(TM) version 1.10.11 compiled on July 10 2021
JVM:          11.0.2 (Oracle Corporation 11.0.2+9)
OS:           Linux 4.14.63-xxxx-std-ipv6-64 amd64

0m3.286s
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
openjdk version "11.0.2" 2019-01-15
OpenJDK Runtime Environment 18.9 (build 11.0.2+9)
OpenJDK 64-Bit Server VM 18.9 (build 11.0.2+9, mixed mode)
Getting tasks: ./gradlew tasks --all
Tasks: publishToMavenLocal,
Found javadoc task
Running: ./gradlew clean -Pgroup=com.github.junit-pioneer -Pversion=issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118 -xtest assemble publishToMavenLocal
> Task :buildSrc:compileJava NO-SOURCE
> Task :buildSrc:compileGroovy NO-SOURCE
> Task :buildSrc:processResources NO-SOURCE
> Task :buildSrc:classes UP-TO-DATE
> Task :buildSrc:jar
> Task :buildSrc:assemble
> Task :buildSrc:compileTestJava NO-SOURCE
> Task :buildSrc:compileTestGroovy NO-SOURCE
> Task :buildSrc:processTestResources NO-SOURCE
> Task :buildSrc:testClasses UP-TO-DATE
> Task :buildSrc:test NO-SOURCE
> Task :buildSrc:check UP-TO-DATE
> Task :buildSrc:build
Maven publication 'maven' pom metadata warnings (silence with 'suppressPomMetadataWarningsFor(variant)'):
  - Variant jacksonApiElements:
      - Declares capability org.junit-pioneer:junit-pioneer-jackson:issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118 which cannot be mapped to Maven
  - Variant jacksonRuntimeElements:
      - Declares capability org.junit-pioneer:junit-pioneer-jackson:issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118 which cannot be mapped to Maven
These issues indicate information that is lost in the published 'pom' metadata file, which may be an issue if the published library is consumed by an old Gradle version or Apache Maven.
The 'module' metadata file, which is used by Gradle 6+ is not affected.
> Task :clean
> Task :generateModuleInfo
> Task :addDependenciesModuleInfo
> Task :compileJava
> Task :processResources
> Task :classes
> Task :jar
> Task :addMainModuleInfo

> Task :javadoc

> Task :javadocJar
> Task :sourcesJar
> Task :assemble
> Task :generateMetadataFileForMavenPublication
> Task :generatePomFileForMavenPublication
> Task :signMavenPublication SKIPPED
> Task :publishMavenPublicationToMavenLocal
> Task :publishToMavenLocal

BUILD SUCCESSFUL in 14s
15 actionable tasks: 15 executed
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
warning: The code being documented uses packages in the unnamed module, but the packages defined in https://junit.org/junit5/docs/current/api/ are in named modules.
1 warning
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
Archive: org.junit-pioneer:junit-pioneer:unspecified
Publication: org.junit-pioneer:junit-pioneer:unspecified
Build tool exit code: 0
Looking for artifacts...
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 -Dhttps.protocols=TLSv1.2
Looking for pom.xml in build directory and ~/.m2
Found artifact: org.junit-pioneer:junit-pioneer:issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118
Found artifact: org.junit-pioneer:junit-pioneer:unspecified
2022-10-08T17:57:43.175376358Z
Exit code: 0

✅ Build artifacts:
com.github.junit-pioneer:junit-pioneer:issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118

Files: 
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/build.log
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118-javadoc.jar
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118-sources.jar
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118.jar
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118.module
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118.pom
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118.pom.md5
com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/junit-pioneer-issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118.pom.sha1

https://jitpack.io/com/github/junit-pioneer/junit-pioneer/issue~677-fix-jitpack-build-v1.3.0-gb5b6319-118/build.log

@Bukama Bukama merged commit ebe3182 into main Oct 9, 2022
@Bukama Bukama deleted the issue/677-fix-jitpack-build branch October 9, 2022 17:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
full-build Triggers full build suite on PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

JitPack fails building Pioneer: "invalid flag: -Xlint:all,-exports"
2 participants