<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta content="text/html;charset=UTF-8" http-equiv="Content-Type"></head><body ><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10pt;"><div>fantastic, thanks for pointing this out!<br></div><div><br></div><div>rgds,<br></div><div>Chin Luh</div><br><div data-zbluepencil-ignore="true" style="" class="zmail_extra"><br><div id="Zm-_Id_-Sgn1">---- On Thu, 31 Oct 2019 04:16:04 +0800 <b>Samuel Gougeon <sgougeon@free.fr></b> wrote ----<br></div><br><blockquote style="border-left: 1px solid rgb(204, 204, 204); padding-left: 6px; margin: 0px 0px 0px 5px;"><div><div class="x_1161150221moz-cite-prefix">Le 30/10/2019 Ã  02:33, Chin Luh Tan a
      Ã©crit :<br></div><blockquote><div style="font-family: Verdana, Arial, Helvetica, sans-serif;font-size: 10.0pt;"><div>Hi Samuel, <br></div><div><br></div><div>I think we could use this instead:<br></div><div><br></div><div>unix_w("Scilex --help  2>&1")<br></div><br><div class="x_1161150221zmail_extra"><br>As you mentioned, the "--help" is Scilab 6 dedicated
          "hardcoded" function, I am yet to look for where is it located
          from the source, if anyone find out, please share here :).<br> <br> For some reason, the output message seems  to have sent to
          stderr(2) instead of stdout(1), so we have to redirect it back
          to stdout for the unix_? to capture it. <br></div></div></blockquote><p>The whole thing is to know which reason. Clearly,  std::cerr is
      intentionally targeted,<br> in the source file \scilab\modules\startup\src\cpp\scilab.cpp:<br> <span class="size" style="font-size:undefinedpx"><span class="colour" style="color:#333333">static void usage(void)<br> {<br>     std::cerr << "Usage: Scilab <options>"
          << std::endl;<br>     std::cerr << "      -e Instruction   :
          execute the scilab instruction given in Instruction argument."
          << std::endl;<br>     std::cerr << "                         -e and
          -f arguments are mutually exclusive." << std::endl;<br>     std::cerr << "      -f File          :
          execute the scilab script given in File argument." <<
          std::endl;<br>     std::cerr << "                         -e and
          -f arguments are mutually exclusive." << std::endl;<br>     std::cerr << "      -quit            : force
          scilab exit after execution of script from -e or -f argument."
          << std::endl;<br>     std::cerr << "                         this
          flag is ignored if it is not used with -e or -f argument."
          << std::endl;<br>     std::cerr << "      -l lang          : Change
          the language of scilab ( default : en_US )." <<
          std::endl;<br>     std::cerr << "      -nw              : Enable
          console mode." << std::endl;<br>     std::cerr << "      -nwni            : Enable
          terminal mode." << std::endl;<br>     std::cerr << "      -ns              : Don't
          execute etc/scilab.start." << std::endl;<br>     std::cerr << "      --help           :
          Display this help." << std::endl;<br>     std::cerr << "      -scihome <dir>   :
          Force SCIHOME to <dir>." << std::endl;<br>     std::cerr << "Developer Trace arguments:"
          << std::endl;<br>     std::cerr << "      --parse-trace    :
          Display bison state machine evolution." << std::endl;<br>     std::cerr << "      --AST-trace      :
          Display ASCII-art AST to be human readable." <<
          std::endl;<br>     std::cerr << "      --pretty-print   :
          Display pretty-printed code, standard Scilab syntax." <<
          std::endl;<br>     std::cerr << " " << std::endl;<br>     std::cerr << "Developer Timer arguments:"
          << std::endl;<br>     std::cerr << "      --AST-timed      : Time
          each AST node." << std::endl;<br>     std::cerr << "      --timed          : Time
          global execution." << std::endl;<br>     std::cerr << " " << std::endl;<br>     std::cerr << "Developer Debug arguments:"
          << std::endl;<br>     std::cerr << "      --no-exec        : Only
          do Lexing/parsing do not execute instructions." <<
          std::endl;<br>     std::cerr << "      --context-dump   :
          Display context status." << std::endl;<br>     std::cerr << "      --exec-verbose   :
          Display command before running it." << std::endl;<br>     std::cerr << "      --timeout delay  : Kill
          the Scilab process after a delay." << std::endl;<br> }<br> </span></span><br></p></div>_______________________________________________<br>users mailing list <br>users@lists.scilab.org <br>http://lists.scilab.org/mailman/listinfo/users <br></blockquote></div><div><br></div></div><br></body></html>