LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - General (https://www.linuxquestions.org/questions/linux-general-1/)
-   -   Saving CLI data in the CLI (https://www.linuxquestions.org/questions/linux-general-1/saving-cli-data-in-the-cli-542795/)

Tons of Fun 04-02-2007 06:41 PM

Saving CLI data in the CLI
 
When using a Live CD, I recently had copied a string of data from the CLI using <ctrl>-C. I wanted to save the data, but couldn't get X to start, and was loaded on a Windows machine that I was visiting. How can I save the data that I copy in the CLI so that I can take it with me if I cannot start X? The machine did not have a floppy, but did have USB ports.

Thanks,

:study:

MS3FGX 04-02-2007 07:04 PM

I'm not sure what you mean exactly.

If you have copied a string of text from the command line, you could just save it to a text file and put it on a removable device or send it over the network.

You could directly pipe a command into a text file as well, something like:

Code:

lspci > devices.txt

Tons of Fun 04-02-2007 07:34 PM

What I did was highlight text from the CLI and copy it with <ctrl> C, and I was not sure how to send it to a text file, like data.txt. If it was already a file, I know that I could use the mv or cp command, but I do not know what command or commands I would use from the CLI to send text that I copied from the CLI with <ctrl> C to a file on my USB stick or a floppy.

Like in your example, instead of lspci, what command would I use to pipe the data that I just copied with <ctrl>C to a file named data.txt?

I hope I was a little more clear this time; I'm sure it's an easy answer, I just cannot figure it out.

Thanks for replying,

General Failure 04-03-2007 12:05 AM

Copy text.
Type echo [PasteTextHere] > data.txt.
That's it.

Tons of Fun 04-03-2007 05:42 AM

I knew it had to be an easy answer, I just couldn't figure it out. Thanks a lot for the help, I'll be trying it out this morning.

Thanks again.

:D


All times are GMT -5. The time now is 11:12 AM.