help-guix
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how can I find the terminal output


From: zimoun
Subject: Re: how can I find the terminal output
Date: Sat, 07 May 2022 17:42:28 +0200

Hi,

On Fri, 06 May 2022 at 20:18, Gottfried <gottfried@posteo.de> wrote:

> How do I have to use "script"?

Only you can answer. ;-)  The question is: what is your needs?  Do you
need to record and track the output for each command?

Personally, I only do that for the very rare cases when I am demoing.
Otherwise, I only redirect the output of a command to a file using ’>’.


> Do I have to enter "script" in the terminal before I start other 
> commands, so that it will start to log my shell?

Yes.

> or can I, after a command with output, enter "script" and it will log my 
> output in a file typescript?

No.

However, you can redo the same command to append the output to a
previous ’typescript’.  For instance, in your terminal:

        ls
        script
        ls
        exit
        pwd
        script -a
        cd /tmp/
        ls
        pwd
        exit

Then the file ’typescript’ contains the session (input and output)
between ’script’ and ’exit’ (included).  Therefore, the first ’pwd’ will
be not recorded.



> I tried several times, but it didn't work. It didn't record anything, 
> when I opened the file typescript.
>
> So can you show me an example how to use it?
> What Options are useful?

Well, have you read the manpage of ’script’?  Type ’man script’.


Hope that helps,
simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]