From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1Hy9t3-000114-Ag for mharc-grub-devel@gnu.org; Tue, 12 Jun 2007 13:10:33 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Hy9t2-00010w-AM for grub-devel@gnu.org; Tue, 12 Jun 2007 13:10:32 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Hy9sz-0000xh-Tg for grub-devel@gnu.org; Tue, 12 Jun 2007 13:10:30 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Hy9sz-0000xb-N8 for grub-devel@gnu.org; Tue, 12 Jun 2007 13:10:29 -0400 Received: from smtp-vbr8.xs4all.nl ([194.109.24.28]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Hy9sz-00010g-IH for grub-devel@gnu.org; Tue, 12 Jun 2007 13:10:29 -0400 Received: from localhost.localdomain (249-174.surfsnel.dsl.internl.net [145.99.174.249]) by smtp-vbr8.xs4all.nl (8.13.8/8.13.8) with ESMTP id l5CHAPIh031316 for ; Tue, 12 Jun 2007 19:10:26 +0200 (CEST) (envelope-from mgerards@xs4all.nl) From: Marco Gerards To: The development of GRUB 2 References: <466E8A17.3030507@raulete.net> <20070612141626.GC1754@aragorn> <466EA924.6090100@raulete.net> Mail-Copies-To: mgerards@xs4all.nl Date: Tue, 12 Jun 2007 19:16:48 +0200 In-Reply-To: <466EA924.6090100@raulete.net> (adrian15@raulete.net's message of "Tue, 12 Jun 2007 16:09:40 +0200") Message-ID: <87abv5ytxb.fsf@xs4all.nl> User-Agent: Gnus/5.110006 (No Gnus v0.6) Emacs/21.4 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: by XS4ALL Virus Scanner X-detected-kernel: FreeBSD 4.6-4.9 Subject: Re: How to call a command from another one 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: Tue, 12 Jun 2007 17:10:32 -0000 adrian15 writes: > Robert Millan escribi=F3: >> On Tue, Jun 12, 2007 at 01:57:11PM +0200, adrian15 wrote: >>> Hi, >>> >>> I want to implement the pause command so that it is the same thing as >>> the echo command with all of its options and also that it stops. >> I don't know how to call other commands, but in this case, maybe grub_pr= intf() >> will be good enough? > > I agree with you but... > > I think it would be a good idea to have a pause message that has the > same options as the echo command because the echo command has some > nice options and because I like to reuse code. Make them share the same file. Call grub_cmd_echo with the same arguments which are used for pause. Before and after that you can do whatever you want. The disadvantage of this approach is that the set of arguments should be the same. -- Marco