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

Add repo jbake-maven-plugin into repo jbake + upgrade to gradle 7 #740

Merged
merged 152 commits into from
Jan 2, 2022

Conversation

ge0ffrey
Copy link
Contributor

@ge0ffrey ge0ffrey commented Dec 28, 2021

Tackles these issues:

  1. A JBake release should automatically release the maven and gradle plugin too. More efficient releases.
  2. The version number of the maven and gradle plugins should match the JBake versions.
    Keep it simple for users: If a new JBake version comes out, I just update my jbake-maven-plugin version, done. No need to figure out which maven/gradle plugin version aligns to which jbake version (for every jbake upgrade too).
  3. The Maven and Gradle versions should use the same asciidoc, markdown, freemarker, etc versions as jbake-core. They should include them all out of the box, so a user doesn't have to explicitly add them in their build files. They shouldn't have to figure out the right asciidoc and freemarker version to use, nor go through all that again every time when upgrading to a new jbake version. The should automatically use the same asciidoc/markdown version as jbake-core unit tests did.
  4. All of this begins with moving the maven and gradle repositories into the gradle repository without loosing git history.

--HG--
extra : amend_source : 31da5144387b274a1c962c35dbcb7746cab6c34a
--HG--
rename : src/main/java/br/com/ingenieux/mojo/jbake/GenerateMojo.java => src/main/java/br/com/ingenieux/mojo/jbake/SeedMojo.java
@jonbullock
Copy link
Member

Thanks @lefou for taking the time to share your thoughts on this, it is very much appreciated. 👍

There are negatives, as you quite rightly point out, but I think the potential positives will outweigh the negatives overall. Especially for users and that is the goal for this.

@ge0ffrey ge0ffrey marked this pull request as ready for review December 30, 2021 08:30
@ge0ffrey ge0ffrey changed the title Merge repo jbake-maven-plugin into repo jbake Merge repo jbake-maven-plugin into repo jbake + upgrade to gradle 7 Dec 30, 2021
@ge0ffrey ge0ffrey changed the title Merge repo jbake-maven-plugin into repo jbake + upgrade to gradle 7 Add repo jbake-maven-plugin into repo jbake + upgrade to gradle 7 Dec 30, 2021
jbake-core/build.gradle Outdated Show resolved Hide resolved
@jonbullock
Copy link
Member

Conducted some local testing and the plugin builds and executes as expected in a sample Maven project. I compared the generated artefact to a previous version and noticed a few things. The pom.xml for the plugin is missing metadata about the plugin (name, license, SCM etc.) and a HelpMojo class is missing (guessing this was automatically generated).

Couldn't remember if the metadata is required for Maven Central so did a check and found this: https://central.sonatype.org/publish/requirements/ which suggests it is.

switch back to maven plugin development gradle plugin from Benedikt
Ritter

https://github.com/britter/maven-plugin-development
@ancho
Copy link
Member

ancho commented Jan 1, 2022

Have a look at the latest commit here https://github.com/ancho/jbake/tree/merge-repo-jbake-maven-plugin
I had to switch the maven development plugin to make it work.

@jonbullock
Copy link
Member

Thanks @ancho that's solved it, with that commit I get the metadata and the HelpMojo class.

@jonbullock jonbullock self-assigned this Jan 1, 2022
@jonbullock jonbullock added this to the v2.7.0 milestone Jan 1, 2022
@ge0ffrey
Copy link
Contributor Author

ge0ffrey commented Jan 2, 2022

Thanks @ancho! Great work!
@jonbullock I fast forwarded this PR to include ancho's last commit too.
(I don't mind if you merge this branch or your local stuff and just close this one - as you see fit)

@jonbullock
Copy link
Member

Thanks so much @ge0ffrey and @ancho

@jonbullock jonbullock merged commit 6461eba into jbake-org:master Jan 2, 2022
@jonbullock jonbullock mentioned this pull request Jan 2, 2022
tarilabs added a commit to tarilabs/drools-website that referenced this pull request Oct 29, 2023
1.
version bumps resolve platform incompatibilities on non-x86 platforms
```
[ERROR] Failed to execute goal org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate (default) on project drools-website: Execution default of goal org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate failed: An API incompatibility was encountered while executing org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate: java.lang.UnsatisfiedLinkError: ... (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64'))
```

2.
avoid the need to specify manually jbake-maven-plugin dependencies version
ref: jbake-org/jbake#740
mariofusco pushed a commit to kiegroup/drools-website that referenced this pull request Oct 30, 2023
1.
version bumps resolve platform incompatibilities on non-x86 platforms
```
[ERROR] Failed to execute goal org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate (default) on project drools-website: Execution default of goal org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate failed: An API incompatibility was encountered while executing org.jbake:jbake-maven-plugin:0.3.6-rc.2:generate: java.lang.UnsatisfiedLinkError: ... (fat file, but missing compatible architecture (have 'i386,x86_64', need 'arm64'))
```

2.
avoid the need to specify manually jbake-maven-plugin dependencies version
ref: jbake-org/jbake#740
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.