title: OS X: equivalent of Linux's wget
body: <p>How can I do an HTTP GET from a Un*x shell script on a stock OS X system? (installing third-party software is not an option, for this has to run on a lot of different systems which I don't have control on).</p>
  
  <p>For example if I start the Mercurial server locally doing a <em>hg serve</em>:</p>
  
  <pre><code>... $ hg serve 
  </code></pre>
  
  <p>And then, from a Linux that has the <em>wget</em> command I do a wget:</p>
  
  <pre><code>... $  wget http://127.0.0.1:8000
  --2010-12-31 22:18:25--  http://127.0.0.1:8000/
  Connecting to 127.0.0.1:8000... connected.
  HTTP request sent, awaiting response... 200 Script output follows
  Length: unspecified [text/html]
  Saving to: `index.html
  </code></pre>
  
  <p>And on the terminal in which I launched the <em>"hg serve"</em> command, I can indeed see that an HTTP GET made its way:</p>
  
  <pre><code>127.0.0.1 - - [30/Dec/2010 22:18:17] "GET / HTTP/1.0" 200 -
  </code></pre>
  
  <p>So on Linux one way to do an HTTP GET from a shell script is to use <em>wget</em> (if that command is installed of course).</p>
  
  <p>What other ways are there to do the equivalent of a <em>wget</em>?  I'm looking, in particular, for something that would work on stock OS X installs.</p>