From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13965 invoked by alias); 17 Jun 2005 21:14:33 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 13951 invoked by uid 22791); 17 Jun 2005 21:14:29 -0000 Received: from nevyn.them.org (HELO nevyn.them.org) (66.93.172.17) by sourceware.org (qpsmtpd/0.30-dev) with ESMTP; Fri, 17 Jun 2005 21:14:29 +0000 Received: from drow by nevyn.them.org with local (Exim 4.51) id 1DjOAW-00042G-3h for gdb-patches@sources.redhat.com; Fri, 17 Jun 2005 17:14:28 -0400 Date: Fri, 17 Jun 2005 21:14:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sources.redhat.com Subject: Re: mi tty commands Message-ID: <20050617211427.GA15201@nevyn.them.org> Mail-Followup-To: gdb-patches@sources.redhat.com References: <20050529205435.GA11243@white> <20050601001440.GB15414@white> <20050601130653.GA17103@white> <20050601174149.GA17309@white> <20050602221644.GA21263@white> <20050613030732.GE9288@nevyn.them.org> <20050617210811.GA27959@white> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20050617210811.GA27959@white> User-Agent: Mutt/1.5.8i X-SW-Source: 2005-06/txt/msg00262.txt.bz2 On Fri, Jun 17, 2005 at 05:08:11PM -0400, Bob Rossi wrote: > > > - c = add_com ("tty", class_run, tty_command, > > > - _("Set terminal for future runs of program being debugged.")); > > > + /* add the filename of the terminal connected to inferior I/O */ > > > + add_setshow_string_noescape_cmd ("inferior-tty", class_run, > > > + &inferior_io_terminal, _("\ > > > +Set terminal for future runs of program being debugged."), _("\ > > > +Show terminal for future runs of program being debugged."), _("\ > > > +Usage: set inferior-tty /dev/pts/1"), NULL, NULL, &setlist, &showlist); > > > set_cmd_completer (c, filename_completer); > > > + add_com_alias ("tty", "set inferior-tty", class_alias, 0); > > > > This seems nice. I was thinking of replacing "tty" with "set tty" > > instead of "set inferior-tty", but I don't have a strong preference one > > way or the other. > > I didn't change this, since there is an alias. However, the more I > think about it, it would be fine with me if this was changed to simply > 'tty'. Eventually, I might add a console-tty, which is the reason I was > more specific with inferior-tty, instead of just tty. What do you think? Right - what we have now is "tty", this patch preserves "tty" and adds "set inferior-tty". Might as well stay with that. It's a little more descriptive. Could you explain what you've got in mind for console-tty? > I do have one problem with this patch, before it can be approved. There > is no file completion for the tty command with the new patch. I can't > figure out how to add file completion with the > add_setshow_string_noescape_cmd command. Do you or anyone else know how > to do this? If it's a filename, perhaps you should be using add_setshow_filename_cmd instead. -- Daniel Jacobowitz CodeSourcery, LLC