unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
From: Jean Louis <bugs@gnu.support>
To: Stefan Monnier <monnier@iro.umontreal.ca>
Cc: emacs-devel@gnu.org
Subject: Re: Mapping file types to major modes
Date: Fri, 23 Sep 2022 19:09:34 +0300	[thread overview]
Message-ID: <Yy3aPi+GcsP1c13J@protected.localdomain> (raw)
In-Reply-To: <jwvv8pem804.fsf-monnier+emacs@gnu.org>

* Stefan Monnier <monnier@iro.umontreal.ca> [2022-09-23 18:48]:
> Emacs has various facilities to decide which major mode to use for which
> file based on its name and/or contents.  All those facilities specify
> directly the mode to use.  This is usually exactly what we want because
> there's only ever 1 major mode for that type.

I agree on good idea that it would be helpful that major modes
correspond to file types, though practically it is not so easy to
determine it. Example is asciidoctor that can in some cases look
completely same as markdown, also txt2tags that may look as markdown
and similar lightweight markup languages. Additionally many
applications produce .txt files which are markdown formatted.

I suggest that upon first invocation where mode is unclear that Emacs
asks user about preferred mode and give him option to understand
descriptions and differences of such modes.

-- 
Jean

Take action in Free Software Foundation campaigns:
https://www.fsf.org/campaigns

In support of Richard M. Stallman
https://stallmansupport.org/



  reply	other threads:[~2022-09-23 16:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-23 15:45 Mapping file types to major modes Stefan Monnier
2022-09-23 16:09 ` Jean Louis [this message]
2022-09-24 19:51 ` Juri Linkov

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

  List information: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to=Yy3aPi+GcsP1c13J@protected.localdomain \
    --to=bugs@gnu.support \
    --cc=emacs-devel@gnu.org \
    --cc=monnier@iro.umontreal.ca \
    /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 public inbox

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

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).