fix: jbang doesn't store additional deps in JAR Class-Path anymore #708
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes #707
Dumb mistake. I should have double-checked.
If possible I'd do a quick-fix release @maxandersen . It's not that bad , but I don't want people depending on this "feature" and then later complain it got broken :-)
To explain that better: right now you could do
jbang run --dep fu:bar:1.0 myfile.java
and alsojava -jar .../path/to/myfile.java.jar
and that would work.... but it shouldn't. The--dep
is for adding dependencies at runtime, it shouldn't be "baked in".But of course people might think it's very useful, you could have provided a whole bunch of deps at compile time but at runtime you don't have to anymore, yay! No! Not yay! :-)
It goes back to the idea of being able to use service loaders etc, it must be possible to specify deps at runtime for that.
Sorry for the long explanation for such a small PR, but I just wanted to make clear the "severity" of the issue.