FileType for Win32 (ver 1.0) Abandoned Freeware Steve P. Millers FileType displays the file type of one or more files. For executable files, it will give details such as 16/32 bit, console/GUI, CPU type, etc. For all other files it will list the registered system description for that type of file. Usage: filetype [/s] [/h] [/e] filespec ... /s Process subdirectories. /h Process hidden/system files/directories. /e Only display executable files. FileType displays detailed type information about one or more files. While listing files, it automatically identifies which files are executables and which files are not. FileType does not just look at the file extension; it actually examines the contents of the file to determine if the file is an executable and if so, what type of executable it is. Therefore, FileType will detect all executable files, regardless of their extension. The following is a list of executable formats recognized by FileType. Architecture: 16-bit, 32-bit Platform: DOS, Windows, Window CE, OS/2, POSIX Subsystem: native, console, graphical (GUI) CPU: x86, MIPS R3000, MIPS R4000, MIPS R10000, MIPS (big-endian), DEC Alpha, IBM PowerPC, Hitachi SH3 For files that are not executable, FileType will scan the registry for the description that is registered with the system for that type of file. For example, "Microsoft Word Document" might be displayed for a file ending with ".doc". These descriptions may vary from computer to computer, depending on what software is installed. Overview of command line syntax (using FOO as the example program) ============================================================================= - Running FOO with a /? option will display the full command line usage. For example, "foo /?" will display the complete help screen for FOO. - All command line options can be specified with either a leading / or -. For example, "foo /?" is equivalent to "foo -?" - Options that do not take extra arguments can be grouped together. For example, "foo /s /h /r *" is equivalent to "foo /shr *" - Options that do take extra arguments can be placed at the end of a grouping. For example, "foo /s /h /r /t3 *" is equivalent to "foo /shrt3 *" - Spaces are optional between options and their arguments. For example, "foo /t3 *" is equivalent to "foo /t 3 *" FOO might take one or more filespecs. A filespec can be any combination of a file, path, directory, or wildcard search string. Here are some example filespecs: . matches all files in the current directory. * matches all files in the current directory. *.exe matches all files with ".exe" extension in the current dir. a*.xl? matches all files in the current directory that start with an "a" and end with ".xl" followed by any single character. readme matches a single file named "readme" in the current dir. c:\bin\* matches all files in the c:\bin directory. c:\bin\ matches all files in the c:\bin directory. c:\bin matches all files in the c:\bin directory. c:\bin\. matches all files in the c:\bin directory. c:\bin\readme matches a single file named "readme" in the c:\bin dir. d:* matches all files in the d: drive's current directory. \\server\share\* matches all files on the specified network share. If FOO takes filespecs, it also supports recursive directory processing. Just add a /s to the command line of FOO, and FOO will expand its file matching search to include all subdirectories under the initial directory for that filespec. For all the examples above, the /s option would repeat the search described for every subdirectory under the starting directory. FOO is smart enough to break apart the path portion of the filespec from the file or wildcard portion. A filespec like "/s c:\bin\readme" will find all files named "readme" in the c:\bin directory and in subdirectories under the c:\bin directory.