Quantcast
Channel: Bashタグが付けられた新着記事 - Qiita
Viewing all articles
Browse latest Browse all 2722

watchコマンドを一定時間のみ実行

$
0
0

watchコマンドを一定時間で終了させたい事があったので、それの覚書

単発実行

curl --head example.com

render1610930685695.gif

定期実行

watch curl --head example.com
# Break with Ctrl-C

render1610930708227.gif

5秒間実行

timeout 5s watch curl --head example.com

render1610930738285.gif


Viewing all articles
Browse latest Browse all 2722

Trending Articles