LoginSignup
1
2

More than 3 years have passed since last update.

[メモ]シェルスクリプトの特殊変数

Posted at
特殊変数 説明
$0 シェルスクリプトのファイル名
\$1 ~ $n 引数
$# 引数の数
$* $0以外の引数を全て1つの文字列として格納
$? 終了ステータス。成功すると0、失敗すると1
$$ 実行時のプロセス番号

参考:本気で学ぶLinux実践入門

1
2
0

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
1
2