Ugh, curl can be a pain, but once you get it, it’s golden. Here’s the deal:
- `-O` saves with the original filename (from the URL).
- `-o` lets you rename it.
For redirects, always use `-L`. And if you’re dealing with huge files, `--limit-rate 1M` throttles the speed so you don’t nuke your connection.
Also, `curl -I [URL]` lets you check headers before downloading—super handy to see if the file exists.
- `-O` saves with the original filename (from the URL).
- `-o` lets you rename it.
For redirects, always use `-L`. And if you’re dealing with huge files, `--limit-rate 1M` throttles the speed so you don’t nuke your connection.
Also, `curl -I [URL]` lets you check headers before downloading—super handy to see if the file exists.
