all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Thien-Thi Nguyen <ttn@gnuvola.org>
To: "Stephen J. Turnbull" <stephen@xemacs.org>
Cc: emacs-devel@gnu.org
Subject: Re: recognizing a file by scanning it
Date: Mon, 28 Apr 2008 05:02:13 +0200	[thread overview]
Message-ID: <87lk2y65sa.fsf@ambire.localdomain> (raw)
In-Reply-To: <87abjfxb19.fsf@uwakimon.sk.tsukuba.ac.jp> (Stephen J. Turnbull's message of "Mon, 28 Apr 2008 06:06:42 +0900")

() "Stephen J. Turnbull" <stephen@xemacs.org>
() Mon, 28 Apr 2008 06:06:42 +0900

   file(1) contains a rather complete set of such heuristics and
   has been stable for a long time.  AFAIK libmagic is free and
   GPL-compatible.

Yes, i believe so.  My concern w/ using libmagic would be
portability, and handling the case where libmagic is not
available.  I envision the feature to be non-optional.

   Also, it might be nice if you could call this facility from
   coding systems (after all, what else is a BOM but file magic?)
   This kind of thing really doesn't need to be in Lisp, and might
   benefit from being in C.

Certainly, in C it can be much faster.  

thi




  reply	other threads:[~2008-04-28  3:02 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-04-27 11:36 recognizing a file by scanning it Thien-Thi Nguyen
2008-04-27 21:06 ` Stephen J. Turnbull
2008-04-28  3:02   ` Thien-Thi Nguyen [this message]
2008-04-28 14:52     ` Stefan Monnier
2008-04-27 21:15 ` Jason Rumney
2008-04-27 22:52   ` Chong Yidong
2008-04-27 23:28     ` Jason Rumney
2008-04-28  3:16       ` Thien-Thi Nguyen
2008-04-28  8:05         ` Jason Rumney
2008-04-28 18:07           ` Reiner Steib
2008-04-28 18:13             ` Jason Rumney

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87lk2y65sa.fsf@ambire.localdomain \
    --to=ttn@gnuvola.org \
    --cc=emacs-devel@gnu.org \
    --cc=stephen@xemacs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.