texlive[45046] Master/texmf-dist/scripts/texlive/tlmgr.pl: better

commits+preining at tug.org commits+preining at tug.org
Tue Aug 15 08:29:04 CEST 2017


Revision: 45046
          http://tug.org/svn/texlive?view=revision&revision=45046
Author:   preining
Date:     2017-08-15 08:29:03 +0200 (Tue, 15 Aug 2017)
Log Message:
-----------
better tlmgr shell machine readability

Modified Paths:
--------------
    trunk/Master/texmf-dist/scripts/texlive/tlmgr.pl

Modified: trunk/Master/texmf-dist/scripts/texlive/tlmgr.pl
===================================================================
--- trunk/Master/texmf-dist/scripts/texlive/tlmgr.pl	2017-08-15 00:17:49 UTC (rev 45045)
+++ trunk/Master/texmf-dist/scripts/texlive/tlmgr.pl	2017-08-15 06:29:03 UTC (rev 45046)
@@ -531,7 +531,7 @@
 
   # --machine-readable is only supported by update.
   if ($::machinereadable && 
-    $action ne "update" && $action ne "install" && $action ne "option") {
+    $action ne "update" && $action ne "install" && $action ne "option" && $action ne "shell") {
     tlwarn("$prg: --machine-readable output not supported for $action\n");
   }
 
@@ -5915,8 +5915,8 @@
     }
     print "$default_prompt " if (!$did_prompt);
     # to make sure that flushing is done properly, we ship out
-    # a new line in autoflush mode:
-    print "\n" if $opts{'autoflush'};
+    # a new line in buffer mode:
+    print "\n" if $::machinereadable;
     my $ans = <STDIN>;
     if (!defined($ans)) {
       # we got Ctrl-D, just break out
@@ -5942,7 +5942,7 @@
       }
       if (!$isok) {
         print("Please answer one of: @guarantee\n");
-        print "\n" if $opts{'autoflush'};
+        print "\n" if $::machinereadable;
         return(&$do_prompt(@savedargs));
       }
     }



More information about the tex-live-commits mailing list