Subject: Re: bug#14732: Package dos-mode for ELPA

From: Eli Zaretskii <[email-masked]>
Date: Mon, 01 Jul 2013 19:50:00 +0300

> Date: Mon, 1 Jul 2013 01:00:02 +0000 (GMT)
> From: Arni Magnusson <[email-masked]>
> cc: [email-masked]
> 
> As for the second point (why not add to `bat-generic-mode'), I have two 
> answers, so please pick the one you prefer:
> 
> 
> (1) I would be honored to prepare a patch to improve the syntax 
> highlighting of `bat-generic-mode'. This patch would be based on existing 
> functionality in `dos-mode' and would provide:
> 
> - highlighting of more commands: at attrib color date dir doskey endlocal 
> erase fc find mkdir more move popd pushd rmdir setlocal sort time title 
> type xcopy
> 
> - highlighting of more control flow keywords: cmd defined else equ exit 
> geq gtr in leq lss neq
> 
> - highlighting of called script: call foo
> 
> - highlighting of %%variable: for %%X in (bark meow) do echo %%X
> 
> - highlighting of defined variable: if defined VAR

I think we prefer this alternative, thanks.  However, to accept such
changes into Emacs, you will need to do legal paperwork, as I don't
see your assignment for Emacs on file at this time.

> (2) There is more to `dos-mode' than syntax highlighting. Perhaps it would 
> make Emacs users happy to introduce progmodes/dos.el and obsolete 
> `bat-generic-mode' in the same elegant way as `javascript-generic-mode' 
> invokes `js-mode'.

There's no need to obsolete a mode, as it isn't doing anything wrong.
It just has only a small number of features.

> This might also make it easier for users to discover this functionality in 
> Emacs. Notice that for over 4 years, there has been a discussion on 
> http://www.emacswiki.org/emacs/DosScripts, without anyone mentioning 
> `bat-generic-mode', perhaps because they were not aware of its existence.

Then I guess we will have to make a better marketing effort this
time.  For example, we could make bat-generic-mode be the default mode
for Windows batch files, which will make users acutely aware of it.