The Psychology of Quality and More
CHAPTER 5 : Naming
5.11 Naming Files and Directories
Files, and the directories that hold those files can use a similar naming convention to variables to describe the functions or files that they contain. They are often more constrained in length than C identifiers, consequently requiring the more severe use of abbreviations.
5.11.1 Naming files
Files are can often be named using a functional grouping prefix, reflecting the subsystem they belong to and the action of the functions that they contain:
winopn, winmov, kbdread, kbdinit
Using the same or similar names to system files (such as stdie.h) should be avoided.
It is common to use a suffix (or 'extension') to describe the type of file - indeed, it is expected by some compilers. The basic subset is '.c' for C source files and '.h' for an included header file. All suffixes should be documented, including reserved system suffixes, such as '.o' for object files, '.y' for 'yacc' files, etc.
For maximum portability, file names should start with an alphabetic character, be alphanumeric, have 8 characters or less in the main name, with no more that three characters in the suffix.
5.11.2 Naming directories
Directory structures are like nested C 'struct's, and can be named in a similar manner.
In this scheme, 'windows' contains all files for the windowing system, 'source' contains all source files, and 'iconize' contains source files for the iconizing functions.
And the big