Want this question answered?
The attrib command is a Recovery Console command used to change the file attributes for a file or directory while in Recovery Console. An attrib command is also available from the Command Prompt. attrib [+r|-r] [+s|-s] [+h|-h] [+c|-c] [filename] +r = This assigns the read-only file attribute to the file or directory. -r = This removes the read-only attribute. +s = This assigns the system file attribute to the file or directory. -s = This removes the system attribute. +h = This assigns the hidden file attribute to the file or directory. -h = This removes the hidden attribute. +c = This assigns the compressed file attribute to the file or directory. -c = This removes the compressed attribute. filename = This is the file or directory that you are wanting to change the attributes of.
Use the file type test: if [ -d $file ]; then echo $file is a directory elif [ -f $file ]; then echo $file is a file else echo $file is not a directory or a file fi
The attrib command is a Recovery Console command used to change the file attributes for a file or directory while in Recovery Console. An attrib command is also available from the Command Prompt. attrib [+r|-r] [+s|-s] [+h|-h] [+c|-c] [filename] +r = This assigns the read-only file attribute to the file or directory. -r = This removes the read-only attribute. +s = This assigns the system file attribute to the file or directory. -s = This removes the system attribute. +h = This assigns the hidden file attribute to the file or directory. -h = This removes the hidden attribute. +c = This assigns the compressed file attribute to the file or directory. -c = This removes the compressed attribute. filename = This is the file or directory that you are wanting to change the attributes of.
The 'touch' command creates a new empty file in Unix.
Mounting a file system is what allows one to access the access, read, and modify it. It doesn't matter where the file system is mounted, either (though an empty directory is preferable). The mount command binds the physical device to whichever directory you choose and calls the proper kernel driver to allow actual file operations.
You rename a directory the same way you rename a file. Use the 'mv' command to rename it.
The pwd command prints the working directory. The working directory is the directory you are "in", where operations on files that don't have an absolute path specified will be performed. For instance, if my working directory is /home/username/stuff, then the command echo "test" > test.txt would place the file test.txt in that directory.
The DOS message "bad command or file name" means that the command you entered was not recognized as an internal command or as an external command in the working directory or path.
The DIR or directory command is located in the system32 directory of Windows. It is an executable file that gives DOS access to a user.
ls is the default command that lists the contents of a directory. vdir is a common alias for the command: ls -al That command lists the contents of a directory as well as information about the file such as owner, group, file size, permissions, last modified, etc.
mv dir1 new_dir mv file file1 rename / move a file or directory
The df utility displays a list of the directory hierarchies available on the file system. NFS is the file system type.