[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Scripting (IMPORTANT!)
From: |
tgingold |
Subject: |
Re: Scripting (IMPORTANT!) |
Date: |
Mon, 09 Oct 2006 14:52:23 +0200 |
User-agent: |
Internet Messaging Program (IMP) 3.2.5 |
Quoting Marco Gerards <address@hidden>:
Hi,
a few remarks:
[...]
> ============
> Menu entries
> ============
>
> Menu entries are added with `menuentry' (or its alias `@'). It's
> important to notice this is not a command. Because it's part of the
> scripting syntax, it can have unique features. A menuentry is like a
> function, especially because it can have arguments!
>
> Syntax: menuentry "Entry name" [arguments...] { body }
It would be nice to be able to add properties to a menuentry. My first
idea is a logo property.
I think this could be done through a new command such as:
logo "Entry name" filename
> Make sure the entry name is properly escaped, otherwise spaces can not
> be included and will be seen as separator. The arguments will become
> semi-variables like #1, #2, etc. These can be used so one menuentry
> can be used as a template for a lot of menuentries. This can best be
> explained with an example:
>
> (inside loop that sets i = 1...x)
> @ "Partition $i" $i { linux /vmlinuz root=/dev/hda#{1} }
Why not substituing variable at creation (unsubstitued one can be escaped) ?
Eg: @ "Partition $i" { linux /vmlinux root=/dev/hda$1 prefix=$$prefix }
Humm maybe too complex ?
Tristan.
- Scripting (IMPORTANT!), Marco Gerards, 2006/10/05
- Re: Scripting (IMPORTANT!), Johan Rydberg, 2006/10/05
- Re: Scripting (IMPORTANT!), Johan Rydberg, 2006/10/05
- Re: Scripting (IMPORTANT!),
tgingold <=
- Re: Scripting (IMPORTANT!), Hollis Blanchard, 2006/10/12
- Re: Scripting (IMPORTANT!), Yoshinori K. Okuji, 2006/10/13
- Re: Scripting (IMPORTANT!), Marco Gerards, 2006/10/13
- Re: Scripting (IMPORTANT!), Yoshinori K. Okuji, 2006/10/13
- Re: Scripting (IMPORTANT!), Marco Gerards, 2006/10/13
- Re: Scripting (IMPORTANT!), Yoshinori K. Okuji, 2006/10/14
- Re: Scripting (IMPORTANT!), Marco Gerards, 2006/10/14
- Re: Scripting (IMPORTANT!), Yoshinori K. Okuji, 2006/10/14