You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iotdb.apache.org by ha...@apache.org on 2020/11/03 16:50:12 UTC

[iotdb] branch master updated: update AbstractCli (#1926)

This is an automated email from the ASF dual-hosted git repository.

haonan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/iotdb.git


The following commit(s) were added to refs/heads/master by this push:
     new 9f83279  update AbstractCli (#1926)
9f83279 is described below

commit 9f83279c21a7932e868e939568a3fa06a40b19c9
Author: Jialin Qiao <qj...@mails.tsinghua.edu.cn>
AuthorDate: Wed Nov 4 00:49:50 2020 +0800

    update AbstractCli (#1926)
---
 cli/src/main/java/org/apache/iotdb/cli/AbstractCli.java | 8 +++-----
 1 file changed, 3 insertions(+), 5 deletions(-)

diff --git a/cli/src/main/java/org/apache/iotdb/cli/AbstractCli.java b/cli/src/main/java/org/apache/iotdb/cli/AbstractCli.java
index fc2c72e..ffc8c39 100644
--- a/cli/src/main/java/org/apache/iotdb/cli/AbstractCli.java
+++ b/cli/src/main/java/org/apache/iotdb/cli/AbstractCli.java
@@ -344,12 +344,11 @@ public abstract class AbstractCli {
       return args;
     } else {
       StringBuilder executeCommand = new StringBuilder();
-      /*for (int j = index + 1; j < args.length; j++) {
+      for (int j = index + 1; j < args.length; j++) {
         executeCommand.append(args[j]).append(" ");
-      }*/
-      executeCommand.append(args[index + 1]);
+      }
       // remove last space
-      //executeCommand.deleteCharAt(executeCommand.length() - 1);
+      executeCommand.deleteCharAt(executeCommand.length() - 1);
       // some bashes may not remove quotes of parameters automatically, remove them in that case
       if (executeCommand.charAt(0) == '\'' || executeCommand.charAt(0) == '\"') {
         executeCommand.deleteCharAt(0);
@@ -361,7 +360,6 @@ public abstract class AbstractCli {
 
       execute = executeCommand.toString();
       hasExecuteSQL = true;
-      // remove "-e" and it's parameter
       args = Arrays.copyOfRange(args, 0, index);
       return args;
     }