LoginSignup
8
9

More than 5 years have passed since last update.

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

Posted at

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

8
9
1

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
  3. You can use dark theme
What you can do with signing up
8
9