Skip to content

Conversation

@koppor
Copy link
Contributor

@koppor koppor commented Jun 30, 2025

--win-console was not functioning in the preview branch

options.addAll("--win-console")

This PR fixes it.

I think, options should be passed in all app-image cases, therefore, I left then in there - but also copied them into configureJPackageArguments

@koppor
Copy link
Contributor Author

koppor commented Jun 30, 2025

Not working

jdk.jpackage.internal.PackagerException: Error: Option [--linux-menu-group] is not valid with type [app-image]

jdk.jpackage.internal.PackagerException: Error: Option [--win-upgrade-uuid] is not valid with type [app-image]	

Working on a fix

@koppor
Copy link
Contributor Author

koppor commented Jun 30, 2025

Fix: Add new option appImageOptions. I could not think of other solutions

@koppor koppor marked this pull request as ready for review June 30, 2025 14:02
@koppor koppor changed the title Add jlinkOptions to JPackage tasks Add appImageOptions to JPackage tasks Jul 1, 2025
@koppor
Copy link
Contributor Author

koppor commented Jul 1, 2025

I merged JabRef/jabref#13401 to keep things going. If we change this logic here, we need to adapt the main JabRef build, too. OK, we need to do in call cases as the local build will stop running for all who have not checked out java-module-packaging

@jjohannes
Copy link
Member

Thank you @koppor. Yet another missing feature. It makes sense to add this. Merging this into the preview branch.

I'll work on adding some tests for all the new features asap to validate that everything is sound and then do a release.

@jjohannes jjohannes merged commit 812aa1f into gradlex-org:preview Jul 2, 2025
@koppor
Copy link
Contributor Author

koppor commented Jul 2, 2025

Thank you 😅

(NNTR, just persisting thoughts)

I was thinking whether I should propose more strong typing. Having dedicated variables for --win-console etc. However, I think, the current "mix" of the plugin is fine: Abstract from the gradle build and pass the parameters for modules etc. nicely to jpackage etc; but also offer to route the other parameters directly down: That way, one can google the semantics of the parameters and there is no cognitive load to transform cli parameters to some variables of a gradle plugin.

@jjohannes jjohannes added this to the 1.1 milestone Jul 2, 2025
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.

2 participants