[opensuse] How to grep a save command in order to save the complete output of hwinfo to a txt file?
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate. Seasonal greetings. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
Am Samstag, 31. Dezember 2016, 10:01:16 schrieb stakanov:
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, What's wrong with # hwinfo > hwinfo.txt
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Sat, 31 Dec 2016 10:01:16 +0100 stakanov <stakanov@eclipso.eu> wrote:
I have to put the complete hwinfo from the cli to a txt outputfile.
hwinfo > outputfile Or did you mean something more complicated?
I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Seasonal greetings.
-- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
stakanov wrote:
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Is this what you're after: hwinfo >txtfile -- Per Jessen, Zürich (-1.6°C) http://www.dns24.ch/ - your free DNS host, made in Switzerland. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
stakanov composed on 2016-12-31 10:01 (UTC+0100):
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Grep would be for capturing some portion(s) of standard output. To capture the complete standard output of hwinfo to a file, use ordinary redirection: hwinfo > hwinfo-output-file.txt -- "The wise are known for their understanding, and pleasant words are persuasive." Proverbs 16:21 (New Living Translation) Team OS/2 ** Reg. Linux User #211409 ** a11y rocks! Felix Miata *** http://fm.no-ip.com/ -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
In data sabato 31 dicembre 2016 04:28:13, Felix Miata ha scritto:
stakanov composed on 2016-12-31 10:01 (UTC+0100):
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Grep would be for capturing some portion(s) of standard output. To capture the complete standard output of hwinfo to a file, use ordinary redirection:
hwinfo > hwinfo-output-file.txt
Ah, thank you very much. Now finally that is clearer to me. Great. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 31/12/16 09:39, stakanov wrote:
In data sabato 31 dicembre 2016 04:28:13, Felix Miata ha scritto:
stakanov composed on 2016-12-31 10:01 (UTC+0100):
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Grep would be for capturing some portion(s) of standard output. To capture the complete standard output of hwinfo to a file, use ordinary redirection:
hwinfo > hwinfo-output-file.txt
Ah, thank you very much. Now finally that is clearer to me. Great.
The other way of doing it which can be very useful - "man tee" hwinfo | tee hwinfo.txt That will display the output on the screen at the same time, rather than just silently dumping it to file. Depends what you want which one you choose ... :-) (That's the trouble with linux - too many options :-) Cheers, Wol -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On 2016-12-31 10:39, stakanov wrote:
In data sabato 31 dicembre 2016 04:28:13, Felix Miata ha scritto:
stakanov composed on 2016-12-31 10:01 (UTC+0100):
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Grep would be for capturing some portion(s) of standard output. To capture the complete standard output of hwinfo to a file, use ordinary redirection:
hwinfo > hwinfo-output-file.txt
Ah, thank you very much. Now finally that is clearer to me. Great.
In the case of hwinfo, read the manual ;-) Telcontar:~ # hwinfo --help Usage: hwinfo [OPTIONS] Probe for hardware. Options: ... --log FILE Write log info to FILE. Don't forget to also specify --<HARDWARE_ITEM> to trigger any device probing. So: hwinfo --all --log hwinfoOutput.txt -- Cheers / Saludos, Carlos E. R. (from 42.2 x86_64 "Malachite" at Telcontar)
In data sabato 31 dicembre 2016 10:01:16, stakanov ha scritto:
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Seasonal greetings.
your command: sudo hwinfo >txtfile Thank you to everybody who answered. Works like charm. -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
On Saturday 31 December 2016, stakanov wrote:
I have to put the complete hwinfo from the cli to a txt outputfile. I recall I can do this somehow with grep, but all the web resources speak about long scripts. Notwithstanding, I recall, a very simple command can do this. If somebody is knowledgeable I would appreciate.
Seasonal greetings.
$ hwinfo > /tmp/hwinfo.txt writes it to /tmp/hwinfo.txt cu, Rudi -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org
participants (8)
-
Carlos E. R.
-
Dave Howorth
-
Felix Miata
-
Markus Koßmann
-
Per Jessen
-
Ruediger Meier
-
stakanov
-
Wols Lists