menuentry format (change?) (Was: Bug#15182)
In an attempt to save the world from disaster, Joey Hess wrote:
> joost witteveen wrote:
> > Yes I have, but then I wouldn't be able to mix old and new syntax any more.
>
> Do you think perhaps we could get rid of old syntax at some point in the
> future? Like debian 2.1? If there were a lintian check for the old syntax, I
> think it would vanish quite quickly.
Ah, nice idea.
An easy test would be something like
head -n 1 $MENUFILE | sed -n -e '/^[^?]/p'
(if it's got zero output, it's new syntax, otherwise it's old).
On the other hand, I could also do some extra work, and say that
the old/new syntax are not allowed to be mixed in one menuentry file
(not very likely anyway). My preference then would be to make an
empty line a seperator between the menuentries, as in
?package(mypackage):tag1=hello
tag2="my
dear"
tag3="or world"
?package(mypackage):tag1=and_so_on
tag2="It's getting boring"
tag3="It must be clear now"
?package(mypackage):tag1="this is it"
I don't like to make the "?package(" string a seperator for the menuentries
for two reasons:
- it's rather counter-intuative. At least I cannot think of anything
similar anywhere else -- usually the end of a section is denoted
by eighter a newline (sh), a ";" (C, pascal, whatever).
Or you have grouped things like "{}", "begin/end", "<a> / </a>"
- I would like to be able to extend the current syntax to things like
? package(mypacage) && package(herpackage): ....
? !package(hispackage): ...
? file("/usr/bin/bash"): ...
? time() > 946684800 : command="echo welcome to the next milleneum" ...
i.e., between the "?" and the ":" a simple test for update-menus, whether
or not to include the concerning menuentry. This would not be possible
if "?package(" would be the string to start a new menuentry.
--
joost witteveen, joostje@debian.org
The upstream maintainer is allowed to do things different
than Debian, but only if he has good reasons to do so.
--
E-mail the word "unsubscribe" to debian-devel-request@lists.debian.org
TO UNSUBSCRIBE FROM THIS MAILING LIST. Trouble? E-mail to listmaster@lists.debian.org
Reply to: