search
LoginSignup
9

More than 5 years have passed since last update.

awkでコマンドの実行結果を変数に入れる方法

getlineを使う
echo "time:" | awk '{ "date" | getline var; print $1" "var}'
time: Tue Jun 9 11:00:44 JST 2015

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
What you can do with signing up
9