# HG changeset patch # User Rik # Date 1426101578 25200 # Node ID e884d58164713ba5de3cd9389b495c6c970a9d3a # Parent 0cc365dada52bb499de2127657f3776a52b5aec2 Remove extra newlines at end of help printout (bug #44504). * __makeinfo__.m: Remove "\n\n" footer generated by makeinfo when producing "plain text" output. diff -r 0cc365dada52 -r e884d5816471 scripts/help/__makeinfo__.m --- a/scripts/help/__makeinfo__.m Tue Mar 10 21:23:54 2015 -0700 +++ b/scripts/help/__makeinfo__.m Wed Mar 11 12:19:38 2015 -0700 @@ -141,6 +141,13 @@ ## Call makeinfo [status, retval] = system (cmd); + ## Clean up extra newlines generated by makeinfo + if (strcmpi (output_type, "plain text")) + if (numel (retval) > 2 && retval(end-1:end) == "\n\n") + retval = retval(1:end-2); + endif + endif + unwind_protect_cleanup if (exist (name, "file")) delete (name);