You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@nlpcraft.apache.org by ar...@apache.org on 2020/08/26 06:42:47 UTC

[incubator-nlpcraft] branch NLPCRAFT-108 updated: WIP.,

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

aradzinski pushed a commit to branch NLPCRAFT-108
in repository https://gitbox.apache.org/repos/asf/incubator-nlpcraft.git


The following commit(s) were added to refs/heads/NLPCRAFT-108 by this push:
     new d4b4ef9  WIP.,
d4b4ef9 is described below

commit d4b4ef957c629572fe6cec0bff93c0571beac88a
Author: Aaron Radzinski <ar...@datalingvo.com>
AuthorDate: Tue Aug 25 23:40:30 2020 -0700

    WIP.,
---
 .../org/apache/nlpcraft/model/tools/cmdline/NCCommandLine.scala     | 2 --
 .../scala/org/apache/nlpcraft/common/ascii/NCAsciiTableSpec.scala   | 6 ++++--
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/nlpcraft/src/main/scala/org/apache/nlpcraft/model/tools/cmdline/NCCommandLine.scala b/nlpcraft/src/main/scala/org/apache/nlpcraft/model/tools/cmdline/NCCommandLine.scala
index f215ccd..f38a9ff 100644
--- a/nlpcraft/src/main/scala/org/apache/nlpcraft/model/tools/cmdline/NCCommandLine.scala
+++ b/nlpcraft/src/main/scala/org/apache/nlpcraft/model/tools/cmdline/NCCommandLine.scala
@@ -137,8 +137,6 @@ object NCCommandLine extends App {
 
         val tbl = NCAsciiTable().margin(left = 4)
 
-        tbl.maxCellWidth = 55
-
         if (params.isEmpty)  // Default - show abbreviated help.
             CMDS.foreach(cmd => tbl += (cmd.names.mkString(", "), cmd.synopsis))
         else if (cmd.isParamPresent("all", params)) { // Show a full format help for all commands.
diff --git a/nlpcraft/src/test/scala/org/apache/nlpcraft/common/ascii/NCAsciiTableSpec.scala b/nlpcraft/src/test/scala/org/apache/nlpcraft/common/ascii/NCAsciiTableSpec.scala
index 2abb4b1..639425f 100644
--- a/nlpcraft/src/test/scala/org/apache/nlpcraft/common/ascii/NCAsciiTableSpec.scala
+++ b/nlpcraft/src/test/scala/org/apache/nlpcraft/common/ascii/NCAsciiTableSpec.scala
@@ -31,7 +31,8 @@ class NCAsciiTableSpec {
 
         t.margin(5, 5, 5, 5)
 
-        t.maxCellWidth = 10
+        t.defaultHeaderStyle = s"${t.defaultHeaderStyle}, maxWidth=10"
+        t.defaultRowStyle = s"${t.defaultRowStyle}, maxWidth=10"
 
         t #= ("Header 1", Seq("Header 2.1", "Header 2.2"), "Header 3")
         t += ("Row 1", Seq("Row 2"), Seq("Row 3.1", "Row 3.2"))
@@ -49,7 +50,8 @@ class NCAsciiTableSpec {
 
         t.margin(5, 5, 5, 5)
 
-        t.maxCellWidth = 10
+        t.defaultHeaderStyle = s"${t.defaultHeaderStyle}, maxWidth=10"
+        t.defaultRowStyle = s"${t.defaultRowStyle}, maxWidth=10"
 
         t #= (Seq("Header 1", "Header 2", "Header 3", "Header 4"): _*)
         t += ("Column 1", "Column 2", "Column 3", "Column 4")