[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Scripting framework

From: Vladimir Serbinenko
Subject: Re: Scripting framework
Date: Thu, 27 Oct 2005 11:51:44 +0200
User-agent: Mozilla Thunderbird 1.0.6 (X11/20050804)

I wrote the scripting support.
The patch can be found under

As in this version there is no arithmethic support I added commands true5 and 
false 5 for testing
They return five times true and then false (true5) or inverse (false5)

1) Positional arguments like $1, $2, ... and $*/$@ 2) Arithmethic module for commands like ((2+3*5)) 3) logical module for commands like [[ -f /boot/vmlinuz ]] 4) break, continue and return commands
5) menu parameters like:
menu --default "Linux" { ... } Can anybody propose the way to generate menu entries from loop?
What about
menu --prepend var=val --prepend val=var ...
Then compiler will expand var=val and put it to the begin of menu
6) Regexp recognizer for case command

In difference with bash ( and ) are not the word separators. So you have to put 
spaces around them in case command
case $x in ( 123 ) ....;; ... esac and not case $x in (123) ....;; ... esac The same with functions. e.g. hello ( ) { .. } or hello () { .. }
and not
hello() { .. }
Command select is not done. Menu should be enough.
Expansions and arrays are NOT the part of scripting but of split_cmdline and 
environment and is not made yet

Unfortunately I have now no more time. So I send this letter as is. More 
information will be available in my next letter and on the site.
Vladimir 'phcoder' Serbinenko

reply via email to

[Prev in Thread] Current Thread [Next in Thread]