]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
scriptreplay: make data log file optional for --summary
authorKarel Zak <kzak@redhat.com>
Wed, 2 Oct 2019 12:22:12 +0000 (14:22 +0200)
committerKarel Zak <kzak@redhat.com>
Tue, 8 Oct 2019 11:11:54 +0000 (13:11 +0200)
Signed-off-by: Karel Zak <kzak@redhat.com>
term-utils/script.1
term-utils/scriptreplay.c

index 158a9ffa9a99d2a77ea87e4b64041754de71f3be..b73420267b6945b3cbd5b92a6fc1729fb4edbc00 100644 (file)
@@ -50,7 +50,11 @@ and to store additional information about the session.
 Since version 2.35
 .B script
 supports multiple streams and allows to log input and output to separate
-files or all the one file.
+files or all the one file.  This version also supports new timing file 
+which records additional information. The command
+.B scriptreplay \-\-summary
+then provides all the information.
+
 .PP
 If the argument
 .I file
index 81906946e4bc592c3051d1eb3c84d68a06fd60d4..609b20f93e515dac7b4a99ed1f7ec48c6744b179 100644 (file)
@@ -243,7 +243,7 @@ main(int argc, char *argv[])
 
        if (!log_tm && idx < argc)
                log_tm = argv[idx++];
-       if (!log_out && !log_in && !log_io)
+       if (!log_out && !summary && !log_in && !log_io)
                log_out = idx < argc ? argv[idx++] : "typescript";
 
        if (!diviopt)
@@ -251,7 +251,7 @@ main(int argc, char *argv[])
 
        if (!log_tm)
                errx(EXIT_FAILURE, _("timing file not specified"));
-       if (!(log_out || log_in || log_io))
+       if (!(log_out || log_in || log_io) && !summary)
                errx(EXIT_FAILURE, _("data log file not specified"));
 
        setup = replay_new_setup();