From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1DhOLR-0005hN-NQ for mharc-grub-devel@gnu.org; Sun, 12 Jun 2005 05:01:31 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1DhOJX-0005b3-7P for grub-devel@gnu.org; Sun, 12 Jun 2005 04:59:31 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1DhOJS-0005a2-QR for grub-devel@gnu.org; Sun, 12 Jun 2005 04:59:27 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1DhOJS-0005UD-Jw for grub-devel@gnu.org; Sun, 12 Jun 2005 04:59:26 -0400 Received: from [194.67.23.121] (helo=mx1.mail.ru) by monty-python.gnu.org with esmtp (Exim 4.34) id 1DhOFU-00079a-34 for grub-devel@gnu.org; Sun, 12 Jun 2005 04:55:20 -0400 Received: from [83.76.15.210] (port=3344 helo=[192.168.1.100]) by mx1.mail.ru with esmtp id 1DhOEf-000E4S-00 for grub-devel@gnu.org; Sun, 12 Jun 2005 12:54:29 +0400 Message-ID: <42ABF841.1050706@list.ru> Date: Sun, 12 Jun 2005 10:54:25 +0200 From: Serbinenko Vladimir User-Agent: Mozilla Thunderbird 1.0.2-1.3.2 (X11/20050324) X-Accept-Language: en-us, en MIME-Version: 1.0 To: The development of GRUB 2 References: <429C6B12.4080608@inma.ucl.ac.be> <429C949E.1080700@inma.ucl.ac.be> <871x7ncoh6.fsf@student.han.nl> <42A41F7E.6040403@inma.ucl.ac.be> <87acm0prkj.fsf@student.han.nl> <20050609230545.M85450@auto.ucl.ac.be> In-Reply-To: <20050609230545.M85450@auto.ucl.ac.be> Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: Scripting and keystrokes X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 12 Jun 2005 09:01:24 -0000 Hello all. I'm back. I wrote nothing last time because I was quite busy. 2 themes I'd like to speak of: 1) Scripting: how make it: three possibilities a) Hand written b) Bison with 2 branches: one executes directly and other saves the commands that are for later execution **UGLY** c) Convert with bison to the structure like enum grub_script_cmd_type {GRUB_SCRIPT_CMD_TYPE_COMMAND,GRUB_SCRIPT_CMD_TYPE_FOR_IN, <...>}; struct grub_script_for_in { char *var; char **list; grub_script_cmd *loop_begin; grub_script_cmd *skip_loop; } struct grub_script_cmd { grub_script_cmd_type type; union { char *command; grub_script_for_in for_in; <...> } } *GOOD SOLUTION IMHO* Which scripting: I propose to make bash-like scripting and make it so close as possible to bash 2) Keystrokes: emulation of keypress: just write keys in buffer before booting. I propose to add array of functions grub_preboot that will be launched between grub_machine_fini and grub_loader_boot_func and functions grub_add_preboot and grub_remove_preboot And command syntax like: keystroke [ [ [...]]] Example keystroke h e l l o Space is needed because some keys can't be written with one symbol like: F1, insert, ... ex: keystroke F8 down enter I'm ready to write both scripting and keystroke. Vladimir Serbinenko