creating and removing directories

  • mkdir command : to create a directory

syntax : $mkdir directory name

ex: $mkdir k2schools

creating multiple directories

$mkdir k2 k21 k23 … ….

  • change directory

Syntax : $cd directory name

$cd k2schools



$cd .. : to change to parent directory

$cd\ : to change to root directory

  • Remove directory
  • $rm directory name : to delete a directory but directory should be empty
  • $rm -r directory name : to remove all files and subdirectories, sub directory files including directory.

Related Posts

You can leave a response, or trackback from your own site.

Leave a Reply

Powered by k2schools
%d bloggers like this: