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

【Bash】変数に値が設定されていない場合にエラーにする方法

$
0
0
set -u set -uを記述しておくと未定義の変数があるとエラーになります。 ${sample:?message} 変数を参照する際に以下のように記述することで変数に値が設定されていない場合にm…

Viewing all articles
Browse latest Browse all 2830

Latest Images

Trending Articles