Why do some applications have files with no extension? [closed]
Solution 1:
There's no established mandate in the Linux world that there must be extensions. Filesystems for UNIX-like operating systems do not separate the extension metadata from the rest of the file name. The dot character is just another character in the main filename. Instead, internal file metadata is popularly encoded within the beginning of the file to show what kind of app opens it.
If a file has no extension, and it is not executable, it's likely plaintext, especially if all uppercase.
Solution 2:
As K7AAY says, there is no strong connection between the filename and the filetype, although I disagree that files with no extension is likely to be plain text. The way to find out with some degree of certainty is to use the file
command:
$ file *
...
libperconaserverclient18-dev_5.5.44-rel37.3-1.jessie_amd64.deb: Debian binary package (format 2.0)
Percona-Server-5.5.44-37.3-r729fbe2-jessie-x86_64-bundle.tar: POSIX tar archive (GNU)
...
The type of an executable text file is read from the first line, if it starts with #!
and contains an absolute path to whichever interpreter the script needs:
$ cat s0
#!/usr/bin/bash
$ file s0
s0: Bourne-Again shell script, ASCII text executable
The path to the interpreter is not checked by file
, so it could point to something non-existent:
$ cat s1
#!/a/very/long/and/winding/path/flimflam
$ file s1
s1: a /a/very/long/and/winding/path/flimflam script, ASCII text executable
Solution 3:
90% of the filenames circled are all uppercase letters. This is addressed in our sister-site Software Engineering:
- Readme.txt vs. README.txt
All-uppercase letters stand out and make the file easily visible which makes sense because it is probably the first thing a new user would want to look at. (Or, at least, should have looked at…) As others have already said, file names starting with a capital letter will be listed before lower-case names in ASCIIbetical sorting (LC_COLLATE=C
) which helps make the file visible at a first glance.
The README
file is part of a bunch of files a user of a free software package would normally expect to find. Others are INSTALL (instructions for building and installing the software), AUTHORS
(list of contributors), COPYING
(license text), HACKING
(how to get started for contributing, maybe including a TODO
list of starting points), NEWS
(recent changes) or ChangeLog (mostly redundant with version control systems).
This is what the GNU Coding Standards have to say about the README
file.
The distribution should contain a file named
README
with a general overview of the package:
- the name of the package;
- the version number of the package, or refer to where in the package the version can be found;
- a general description of what the package does;
- a reference to the file
INSTALL
, which should in turn contain an explanation of the installation procedure;- a brief explanation of any unusual top-level directories or files, or other hints for readers to find their way around the source;
- a reference to the file which contains the copying conditions. The GNU GPL, if used, should be in a file called COPYING. If the GNU LGPL is used, it should be in a file called
COPYING
.LESSER
.
Developers interested in file naming conventions should visit Software Engineering site.