|
From: | Pascal Quesseveur |
Subject: | Re: Questions about bat-generic-mode |
Date: | Mon, 21 Jan 2013 11:18:08 +0100 |
User-agent: | Gnus/5.13 (Gnus v5.13) Emacs/24.2 (windows-nt) |
>"OG" == Oleksandr Gavenko <gavenkoa@gmail.com> writes: OG> 3 years ago I also have desire to make patch that provide OG> highlighting of '::' as comment syntax and want 'M-;' OG> (comment-dwim) be able uncomment such regions as I involved in OG> project with many batch files with such commenting style... One solution is to use file variables. Comments starting with :: are correctly processed by putting the following line at top of each batch file. :: -*-coding: iso-latin-1-dos; comment-start:"::" -*- Regarding the coding I observed that when using a dos encoding fontification doesn't work as expected: keywords set and goto are not fontified when they are at lines beginning. It comes from the regex: '("[ \t\n|]\\<\\([gG][oO][tT][oO]\\)\\>[ \t]*\\(:?\\sw+\\)?" I think it should be better to use [:space:]. OG> So stuck with bat-generic-mode. Feature that I like and which is OG> missing is an indentation for batch parentheses syntax: OG> if exist file.txt ( OG> echo xxx OG> ) else ( OG> echo yyy OG> ) +1 -- Pascal Quesseveur pascal.quesseveur@free.fr
[Prev in Thread] | Current Thread | [Next in Thread] |