Need to grab a file from the command line? cURL is your superpower! This versatile tool isn't just for displaying web pages; it's a file download ninja. Here's the lowdown:
At its simplest, the command `curl -O [URL_of_the_file]` downloads a file, saving it with the same name as on the server. The `-O` (capital O) option is key here; it tells cURL to save the output as a file.
Want to rename the file? Use the `-o` (lowercase o) option followed by the desired filename: `curl -o new_filename.zip [URL_of_the_file]`. This downloads the file and saves it as 'new_filename.zip'.
Bonus Tip: Add `-C -` for resuming interrupted downloads. `curl -C - -O [URL_of_the_file]` This picks up where you left off, saving you time and bandwidth. So, ditch the browser and embrace the power of cURL for efficient file downloading!