When I do

lynx --dump http://data.iana.org/TLD/tlds-alpha-by-domain.txt

It outputs the content on this web page but when I do

lynx --dump https://code.wireshark.org/review/gitweb?p=wireshark.git;a=blob_plain;f=manuf

It dumps something else than what is presented in the browser.

Why the first command is working but the second command is not working and how do I make it work?

1 Answer 1

lynx --dump 'https://code.wireshark.org/review/gitweb?p=wireshark.git;a=blob_plain;f=manuf'

You need to quote the URL in this case since it contains ;. The semicolons delimit commands in the shell and will not be part of the URL if the URL is not properly quoted.

In fact, the bits in-between the semi colons will be interpreted as commands, which means that you now have shell variables called a and f:

$ echo "$a"

$ echo "$f"

The other reason that the URL needs to be quoted is that it contains a shell filename globbing character: ?.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.