[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: mailcap viewers in dired; gnus-dired.el, mailcap.el

From: Richard Stallman
Subject: Re: mailcap viewers in dired; gnus-dired.el, mailcap.el
Date: Sun, 14 Oct 2007 21:37:32 -0400

    The current versions of `mailcap.el' and `gnus-dired.el' have some
    dependencies on Gnus.  I'm working on reducing these dependencies so
    that it should possible to use them in other parts of Emacs without
    loading significant parts of Gnus (probably `gnus-dired.el' should be
    renamed, e.g. to `dired-mime.el').

Thanks for doing that.  It needs to be done, to make Emacs clean
and well organized.

However, it would be even better to install these features
in the right place to start with.

I've seen several examples where Gnus developers added to Gnus a
general facility which isn't specificly for reading news or mail.
That's not the way to add these facilities.  They ought to be
added in the right place, as separate facilities in Emacs.

Can we arrange with Gnus maintainers to do this differently?

Juri wrote:

    I think the goal is not to fix gnus-dired.el to not load unnecessary
    packages when only one function is needed from this file, because this
    file is already ad-hoc and contains unrelated commands.  I think we should
    only look at this file as an example of using the mailcap mechanism and
    create a more general commands not in the gnus directory.

I agree.

    > `!' (`dired-do-shell-command') is not exactly what
    > `gnus-dired-find-file-mailcap' does.  In mailcap.el you can also
    > specify Emacs-internal handling, IIRC.

    This is an interesting problem.  It seems that Emacs-internal handling in
    mailcap-mime-data mostly duplicates auto-mode-alist, isn't it?

If this is a matter of deciding how to handle an attachment based on
its mime type, I do not see that as redundant with `auto-mode-alist'.
That decides how to handle a file based on its name.  A file does
not carry anything with it analogous to a stated mime type.
You only have the file name and the data (magic numbers).

such a 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]