Here's a start on the solution:

> script --command "sudo shutdown -h now" --append /home/user/Documents/ShutdownBlinkies/text.txt

And the first result is:

> Script started on Tue 15 Sep 2015 08:56:42 AM EDT
> [sudo] password for user:
>
> Script done on Tue 15 Sep 2015 08:56:58 AM EDT

Of course, we'll have to wait & see, as during _this_ shutdown, nothing momentarily appeared as white text on a black background just before the Plymouth screen, and nothing made it into that text file, not even my password.

It's important that the --command option appear before the --append option; the reverse order gets an error message and won't execute. Also, in contrast to "man script", the command must be enclosed in quotes, not carats as in .

Reply via email to