Open dkamenov opened 11 months ago
Right we need to add a way to customise how that check works.
Workaround would be to copy existing template https://github.com/spring-projects/spring-shell/blob/main/spring-shell-core/src/main/resources/org/springframework/shell/component/path-input-default.stg, modify and package it and set it in a same way as it's done in https://github.com/spring-projects/spring-shell/blob/6dd038830f8d3416bcb034a5717323bfd76ec838/spring-shell-core/src/main/java/org/springframework/shell/component/PathInput.java#L62.
I have a use case whereby the user should select an existing directory, however they see
x Directory exists
which looks like an error message. It seems this behavior is hardcoded inPathInput.checkPath()
Observed on 2.1.12
code sample