Linux Commands Training Quick Tips - Understand How to Use Linux Directory and File Names - Red Hat
Linux directory and file names are “case sensitive” and can be up to 255 characters in length. To avoid using one of the many (approximately twenty) “illegal” characters, just use the letters a-z, A-Z and the numbers 0-9 for your Linux directory and file names. To make your Linux commands easier to run, you may want to always use lower case letters for directory and file names. Some programs will not work properly with directories and files that contain spaces. Therefore, it is best to avoid using spaces and use the – (dash) or _ (underscore) character instead, if necessary. A – (dash) is often useful in a directory or file name – to make a directory or file name easier to read. A directory or file name can contain a suffix (a.k.a. file extension) at the end of the directory or file name. This is a . (dot) followed by one or more characters, such as “ .o “, “ .ps ” and “ .png “. It can even include another . (...