[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Changing buffer mode
From: |
carlmarcos |
Subject: |
Re: Changing buffer mode |
Date: |
Fri, 22 Jul 2022 20:36:35 +0200 (CEST) |
Jul 22, 2022, 18:21 by incal@dataswamp.org:
> carlmarcos--- via Users list for the GNU Emacs text editor wrote:
>
>> From studying your code and my original code. Do you
>> approve of it, or could it be improved a bit more?
>>
>
> It looks good I guess but I don't think it's a good idea to
> begin with, I think it's better to let Emacs handle this for
> you, and if it doesn't the way you'd expect or like,
> configure it, e.g.
>
> ;;; -*- lexical-binding: t -*-
> ;;
> ;; this file:
> ;; https://dataswamp.org/~incal/emacs-init/mode-by-filename.el
>
> (setq auto-mode-alist `(
> ("\\.bal\\'" . balance-mode)
> ("\\.cl\\'" . common-lisp-mode)
> ("\\.dat\\'" . gnuplot-mode)
> ("\\.gpi\\'" . gnuplot-mode)
> ("\\.grm\\'" . sml-mode)
> ("\\.lu\\'" . lua-mode)
> ("\\.nqp\\'" . perl-mode)
> ("\\.php\\'" . html-mode)
> ("\\.pic\\'" . nroff-mode)
> ("\\.pl\\'" . prolog-mode)
> ("\\.sed\\'" . conf-mode)
> ("\\.service\\'" . conf-mode)
> ("\\.tap\\'" . gcode-mode)
> ("\\.tex\\'" . latex-mode)
> ("\\.xr\\'" . conf-xdefaults-mode)
> ("keys\\'" . conf-mode)
> ("*" . text-mode)
> ,@auto-mode-alist) )
>
I have done that actually. But sometimes I introduce some tags that allow
some tools to be used if I switch to another mode, even though it
is not the mode usually associated with a particular file type.
- Re: Changing buffer mode, (continued)
- Re: Changing buffer mode, Emanuel Berg, 2022/07/21
- Re: Changing buffer mode, carlmarcos, 2022/07/21
- Re: Changing buffer mode, carlmarcos, 2022/07/22
- Re: Changing buffer mode, Emanuel Berg, 2022/07/22
- Re: Changing buffer mode, carlmarcos, 2022/07/22
- Re: Changing buffer mode, Emanuel Berg, 2022/07/22
- Re: Changing buffer mode,
carlmarcos <=
Re: Changing buffer mode, Jean Louis, 2022/07/21