![]() ![]() ![]() You can also use mv to rename a file since that operation is a special case of moving it: mv file1.txt file2.txt ls Command It takes two arguments: a file name (or directory name) and a directory path. The mv command allows you to move a file or folder to any directory. This means that rm will delete any given directories, and all the files underneath them, including any subdirectories. To do so, use one of the following options:Īll these options are equivalent and they will delete files recursively. It also allows you to delete populated directories using specific options. All it requires is the path to the file you want to delete: rm The rm (remove) command allows you to delete specific files from directories. Make sure you delete child directories before any of their parents, or the parent directories will not be empty when rmdir tries to remove them: rmdir rm Command If you want to delete many separate empty directories, the order can be important. The rmdir command can delete one or more directories at a time, the only requirement is that they should be empty. The rmdir (remove directory) command removes empty directories. This will create a new subdirectory of the directory you are currently in. All you need to provide is the desired directory name: mkdir Mkdir stands for make directory and, as the name suggests, it allows you to create a new directory.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |