DEV Community

Kuldeep Singh
Kuldeep Singh

Posted on

Download file using curl

Sometime i need to use curl to download things from web as a developer here is a quick command if you forget it.

curl -o <outputfilename> <downloadlink>
Enter fullscreen mode Exit fullscreen mode

download & extract with same command

curl -L <downloadfileurl> | tar zx
Enter fullscreen mode Exit fullscreen mode

also if it is zip file that you are downloading, You can use below tar command:

tar -xf archive.tar
Enter fullscreen mode Exit fullscreen mode

Top comments (0)