Linux 上の curl のコマンド オプションの混乱

Linux 上の curl のコマンド オプションの混乱

signの機能は何でしょうか@?コマンドの例を以下に示します。

curl -w "@curl-format.txt" -o /dev/null -s "http://wordpress.com/"

関連する背景情報はこちら

https://stackoverflow.com/questions/18215389/how-do-i-measure-request-and-response-times-at-once-using-curl

答え1

指定されたファイルからフォーマットを読み取ることを意味します。

マニュアルより:

  -w, --write-out <format>
    Defines  what  to  display on stdout after a completed
and successful operation. The format is a string that may contain
plain text mixed with any number of variables. The string can be 
specified as "string", to get read from a particular file you
specify it "@filename" and to tell curl to read the format from
          stdin you write "@-".

このように @ を使用するのはかなり一般的で、curl はいくつかの場所でこれを使用し、他のコマンドも同様に使用します。

関連情報