You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by mo...@apache.org on 2022/05/26 00:44:06 UTC

[incubator-doris] branch master updated: [fix](help) fix bug of help command (#9761)

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

morningman pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-doris.git


The following commit(s) were added to refs/heads/master by this push:
     new 32a210f426 [fix](help) fix bug of help command (#9761)
32a210f426 is described below

commit 32a210f426f9422a971a1e0157a349c6f88c9dcd
Author: Mingyu Chen <mo...@gmail.com>
AuthorDate: Thu May 26 08:44:00 2022 +0800

    [fix](help) fix bug of help command (#9761)
    
    This bug is introduced from #9306, that user need to execute
    "help stream-load" to show the help doc.
    But actually, it should be "help stream load".
---
 fe/fe-core/src/main/java/org/apache/doris/common/MarkDownParser.java | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/fe/fe-core/src/main/java/org/apache/doris/common/MarkDownParser.java b/fe/fe-core/src/main/java/org/apache/doris/common/MarkDownParser.java
index eced29b736..200c106003 100755
--- a/fe/fe-core/src/main/java/org/apache/doris/common/MarkDownParser.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/common/MarkDownParser.java
@@ -166,7 +166,9 @@ public class MarkDownParser {
         }
         // Note that multiple line breaks at content's end will be merged to be one,
         // and other whitespace characters will be deleted.
-        return Maps.immutableEntry(key.substring(headLevel).trim(),
+        // Also, the header in md file is like "## STREAM-LOAD", we need to convert it to "STREAM LOAD",
+        // so that we can execute "help stream load" to show the help doc.
+        return Maps.immutableEntry(key.substring(headLevel).trim().replaceAll("-", " "),
                 sb.toString().replaceAll("\\s+$", "\n"));
     }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org