szetszwo commented on code in PR #711:
URL: https://github.com/apache/ratis/pull/711#discussion_r944192133
##########
ratis-shell/src/main/libexec/ratis-shell-config.sh:
##########
@@ -58,6 +59,16 @@ if [[ ${JAVA_MAJORMINOR} != 001008 && ${JAVA_MAJOR} != 011
]]; then
exit 1
fi
+local RATIS_SHELL_CLASSPATH
+
+while read -d '' -r jarfile ; do
+ if [[ "$RATIS_SHELL_CLASSPATH" == "" ]]; then
+ RATIS_SHELL_CLASSPATH="$jarfile";
+ else
+ RATIS_SHELL_CLASSPATH="$RATIS_SHELL_CLASSPATH":"$jarfile"
+ fi
+done < <(find "$RATIS_SHELL_LIB_DIR" ! -type d -name '*.jar' -print0 | sort -z)
Review Comment:
There is a syntax error:
```shell
$sh ./bin/ratis -e
/Users/szetszwo/Downloads/2.3.0/apache-ratis-3.0.0-SNAPSHOT-bin/bin/../libexec/ratis-shell-config.sh:
line 70: syntax error near unexpected token `<'
/Users/szetszwo/Downloads/2.3.0/apache-ratis-3.0.0-SNAPSHOT-bin/bin/../libexec/ratis-shell-config.sh:
line 70: `done < <(find "$RATIS_SHELL_LIB_DIR" ! -type d -name '*.jar' -print0
| sort -z)'
Unsupported command -e
Usage: ratis COMMAND [GENERIC_COMMAND_OPTIONS] [COMMAND_ARGS]
COMMAND is one of:
-e sh Command line tool for ratis
GENERIC_COMMAND_OPTIONS supports:
-e -D<property=value> Use a value for a given ratis-shell property
Commands print help when invoked without parameters.
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]