* Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html
@ 2008-11-24 14:47 Decebal
2008-11-25 14:17 ` Xah Lee
0 siblings, 1 reply; 4+ messages in thread
From: Decebal @ 2008-11-24 14:47 UTC (permalink / raw)
To: help-gnu-emacs
On this page there is the following code:
(setq auto-mode-alist
(append
;; File name (within directory) starts with a dot.
'(("/\\.[^/]*\\'" . fundamental-mode)
;; File name has no dot.
("[^\\./]*\\'" . fundamental-mode)
;; File name ends in `.C'.
("\\.C\\'" . c++-mode))
auto-mode-alist))
But the rule for a file name without a dot should be:
("/[^\\./]*\\'" . fundamental-mode)
Where should I tell this so that the error could be modified?
Also on some places end of the filename is written like \\' and on
other places like $. What is the difference between those two?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html
2008-11-24 14:47 Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html Decebal
@ 2008-11-25 14:17 ` Xah Lee
2008-11-26 10:09 ` Decebal
0 siblings, 1 reply; 4+ messages in thread
From: Xah Lee @ 2008-11-25 14:17 UTC (permalink / raw)
To: help-gnu-emacs
On Nov 24, 6:47 am, Decebal <CLDWester...@gmail.com> wrote:
> On this page there is the following code:
> (setq auto-mode-alist
> (append
> ;; File name (within directory) starts with a dot.
> '(("/\\.[^/]*\\'" . fundamental-mode)
> ;; File name has no dot.
> ("[^\\./]*\\'" . fundamental-mode)
> ;; File name ends in `.C'.
> ("\\.C\\'" . c++-mode))
> auto-mode-alist))
>
> But the rule for a file name without a dot should be:
> ("/[^\\./]*\\'" . fundamental-mode)
>
> Where should I tell this so that the error could be modified?
Do Alt+x report-emacs-bug.
> Also on some places end of the filename is written like \\' and on
> other places like $. What is the difference between those two?
• How To Install Emacs Packages
http://xahlee.org/emacs/emacs_installing_packages.html
Quote:
«
(add-to-list 'auto-mode-alist '("\\.js\\'" . js2-mode))
Note: The double backslash in the string “\\.js\\'” is used to escape
the backslash. So, the regex engine just got “\.js\'”. The “\.” is to
match a period. The “\'” is one of emacs special regex syntax, to
match end of a string.
»
See:
• Regexp Backslash - GNU Emacs Lisp Reference Manual
http://xahlee.org/elisp/Regexp-Backslash.html
Strictly speaking, using “\” is more proper, but often “$” works too
unless the file name contains newline char. (thanks to Barry who
explained this earlier here)
Xah
∑ http://xahlee.org/
☄
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html
2008-11-25 14:17 ` Xah Lee
@ 2008-11-26 10:09 ` Decebal
2008-11-26 13:39 ` Xah Lee
0 siblings, 1 reply; 4+ messages in thread
From: Decebal @ 2008-11-26 10:09 UTC (permalink / raw)
To: help-gnu-emacs
On Nov 25, 3:17 pm, Xah Lee <xah...@gmail.com> wrote:
> > But the rule for a file name without a dot should be:
> > ("/[^\\./]*\\'" . fundamental-mode)
>
> > Where should I tell this so that the error could be modified?
>
> Do Alt+x report-emacs-bug.
If I understand it correctly I need to have Emacs configured to send e-
mail, but I found that I can send the bug to bug-gnu-emacs@gnu.org.
I'll do that.
> > Also on some places end of the filename is written like \\' and on
> > other places like $. What is the difference between those two?
> Strictly speaking, using “\” is more proper, but often “$” works too
> unless the file name contains newline char. (thanks to Barry who
> explained this earlier here)
In my case the two would be equivalent (I never have a filename with a
newline in it), but I'll change the occurences with the better one.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html
2008-11-26 10:09 ` Decebal
@ 2008-11-26 13:39 ` Xah Lee
0 siblings, 0 replies; 4+ messages in thread
From: Xah Lee @ 2008-11-26 13:39 UTC (permalink / raw)
To: help-gnu-emacs
On Nov 26, 2:09 am, Decebal <CLDWester...@gmail.com> wrote:
> > Do Alt+x report-emacs-bug.
>
> If I understand it correctly I need to have Emacs configured to send e-
> mail, but I found that I can send the bug to bug-gnu-em...@gnu.org.
> I'll do that.
me too thought that emacs needs to be config'd in order to send email.
But sometimes last year i realized by accident that whan i do C-c C-c
in mail mode, it nicely switch me to Apple mail app, with a new
compose mail window, with all fields filled like i had in emacs, and
all i have to do is click send.
This is Carbon Emacs for the Mac. I don't know how it is in Windows or
Linux... maybe it is as nice.
Xah
∑ http://xahlee.org/
☄
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-11-26 13:39 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-11-24 14:47 Error on http://www.gnu.org/software/emacs/elisp/html_node/Auto-Major-Mode.html Decebal
2008-11-25 14:17 ` Xah Lee
2008-11-26 10:09 ` Decebal
2008-11-26 13:39 ` Xah Lee
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.