How to do something like this correctly?
$: lshw -html > /tmp/specs.html < firefox
$: firefox < "lshw -html > /tmp/specs.html"
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It only takes a minute to sign up.Sign up to join this community
You should output lshw to a file, and open that file with firefox, as follows:
lshw -html >/tmp/specs.html && firefox /tmp/specs.html
sudo lshw -html >/tmp/specs.html && firefox /tmp/specs.html
Update: Following not uses temp files, but need bcat
Install bcat package:
sudo apt install ruby-bcat
Then the command you want is simple
lshw -html|bcat -b firefox
bcat help output:
Pipe to browser utility. Read standard input, possibly one or more s, and write concatenated / formatted output to browser.