Chapter 8. Working with wget and curl

This chapter will show how to use wget and curl to gather information directly from the internet.

The topics covered in this chapter are:

  • Show how to get information using wget.
  • Show how to get information using curl.

Scripts that can gather data in this way can be very powerful tools to have at your disposal. As you will see from this chapter, you can get stock quotes, lake levels, just about anything automatically from web sites anywhere in the world.

Introducing the wget program

You may have already heard about or even used the wget program. It is a command line utility that can be used to download files from the Internet.

Here is a screenshot showing wget in its most simplest form:

wget options

In the output you ...

Get Linux Shell Scripting Bootcamp now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.