mirror of
https://github.com/apple/pkl.git
synced 2026-05-23 07:17:05 +02:00
Update JLine to 4.x (#1511)
- Remove dependency org.fusesource.jansi:jansi - In 4.x, org.fusesource.jansi:jansi was replaced with org.jline:jansi. Instead of adding this new dependency, this commit replaces Pkl’s single Jansi usage with custom code that preserves existing behavior. Fixing existing ANSI quirks is left for a future PR. - Replace jline-terminal-ansi with jline-terminal-jni - In 4.x, only -jni and -ffm are available (-ffm requires Java 22+) - Configure native-image build for jline-terminal-jni As updating JLine is delicate, I manually tested `pkl repl` and `jpkl repl` on Windows 11 (using Windows Terminal) and on Ubuntu, and found no issues. However, I do not have access to a macOS machine.
This commit is contained in:
@@ -119,6 +119,8 @@ abstract class NativeImageBuild : DefaultTask() {
|
||||
add("--initialize-at-build-time=")
|
||||
// needed for messagepack-java (see https://github.com/msgpack/msgpack-java/issues/600)
|
||||
add("--initialize-at-run-time=org.msgpack.core.buffer.DirectBufferAccess")
|
||||
// needed for jline-terminal-jni
|
||||
add("--initialize-at-run-time=org.jline.nativ,org.jline.terminal.impl.jni")
|
||||
add("--no-fallback")
|
||||
add("-H:IncludeResources=org/pkl/core/stdlib/.*\\.pkl")
|
||||
add("-H:IncludeResources=org/jline/utils/.*")
|
||||
|
||||
Reference in New Issue
Block a user