デバッグ時
curl -v http://localhost
ヘッダのみ取得
curl --head http://localhost
※利用するプロキシや、CDNなどで--headをつけると、意図しないレスポンスが帰ってくる可能性あり。
ヘッダ付与(例はUA)
curl --head -H 'User-Agent: Mozilla/5.0 (compatible; MSIE 10.0; Windows NT 6.1)' http://localhost
catの出力をそのまま、curlでpost
cat hoge.txt | curl http://localhost/ -X POST -d @-