LoginSignup
17
10

More than 5 years have passed since last update.

階層の深いディレクトリをmkdirする方法

Posted at

階層の深いディレクトリをmkdirするには、-pオプションを使う。

例えば今いるディレクトリ階層の配下に10階層分のディレクトリを作成すると以下になる。

$ mkdir -p A0/A1/A2/A3/A4/A5/A6/A7/A8/A9

-pオプションを使わないとエラーとなる。

17
10
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
17
10