Skip to content

Latest commit

 

History

History
30 lines (21 loc) · 439 Bytes

curl.md

File metadata and controls

30 lines (21 loc) · 439 Bytes

curl

下载文件

  • -O 下载文件并以原名保存到当前目录中
  • -o 指定下载后文件的名字
  • -C 断点续传

eg:

$ curl https://progit2.s3.amazonaws.com/zh/2015-12-02-9d8a9/progit-zh.936.pdf -O -C 0

GET 请求

$ curl example.com/form.cgi?data=xxx

POST 请求

$ curl -X POST --data "data=xxx" example.com/form.cgi

其它参数

  • --user-agent
  • --cookie
  • --header