The Debian/Ubuntu effort needs significant work on its documentation (rather like the J effort, come to think of it). For some reason, good copy editing and consistent documentation doesn't get enough effort put into it.
In Debian's case, it comes from inadequate cooperation with the upstream developers. More specifically, when modifying upstream packages because of "policy reasons" the documentation should be patched to be consistent with the behavior. (In J's case, however, it's probably my lack of effort as much as anything else.) That said, here's how to get a quick look at what should be documented for this example: $ sudo strace file /usr/bin/file 2>&1 | grep /magic | cut -f2 -d'"' | sort -u /etc/magic /etc/magic.mgc /usr/share/misc/magic.mgc (That's an older version of Ubuntu.) The moral of the story is that just because something exists doesn't mean that it's used (nor does it mean that it should be used). Thanks, -- Raul On Tue, Oct 6, 2015 at 3:56 PM, Michael Dykman <[email protected]> wrote: > I was expecting to see those text files on my Ubuntu 14.04 but my > /usr/share/file/magic directory is empty, only the mgc is populated. > > On Tue, Oct 6, 2015, 1:39 PM Dan Bron <[email protected]> wrote: > >> Michael Dykman wrote: >> > On my Ubuntu system, the database underlying the file command is found at >> > /usr/share/file/magic.mgc . >> > >> > It is a binary file; >> >> That binary file is compiled from all the plain-text files in >> /usr/share/file/magic . >> >> The format for those “magic files” (aka patterns, signatures) is in the >> man pages for “file”. Here’s one transcript available on the web: >> >> http://man7.org/linux/man-pages/man4/magic.4.html < >> http://man7.org/linux/man-pages/man4/magic.4.html> >> >> -Dan >> >> >> ---------------------------------------------------------------------- >> For information about J forums see http://www.jsoftware.com/forums.htm > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm
