command linux create directory code example Example 1: how to create a directory in terminal mkdir new-folder Example 2: create directory linux mkdir /tmp/newdir