-
Notifications
You must be signed in to change notification settings - Fork 238
Description
Every form of command exection/checking first checks if the sub-registries can handle a command, then check if it is a local command if it does not exist later, and then if it is a potential console command.
There is one outlier, and that is https://github.com/gnodet/jline3/blob/d63b3efce6c730c15554a0a71997fb974de4bffb/console/src/main/java/org/jline/console/impl/SystemRegistryImpl.java#L1233
(local -> custom -> scripts)
Here the local check is done first, before checking for local commands later. This unfortunately makes it impossible to (temporarily) override builtin commands like exit and clear.
Other check examples (pretty consistent):
https://github.com/gnodet/jline3/blob/d63b3efce6c730c15554a0a71997fb974de4bffb/console/src/main/java/org/jline/console/impl/SystemRegistryImpl.java#L414
(custom -> local -> console)
https://github.com/gnodet/jline3/blob/d63b3efce6c730c15554a0a71997fb974de4bffb/console/src/main/java/org/jline/console/impl/SystemRegistryImpl.java#L341
(custom -> scripts -> local)
https://github.com/gnodet/jline3/blob/d63b3efce6c730c15554a0a71997fb974de4bffb/console/src/main/java/org/jline/console/impl/SystemRegistryImpl.java#L214
(custom -> scripts -> local)