This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: >, >>, and "tee" operators


On Tue, Jul 23, 2002 at 01:17:04PM -0600, Tom Tromey wrote:
> >>>>> "Daniel" == Daniel Jacobowitz <drow@mvista.com> writes:
> 
> Daniel> Here we go.  They only work quite right for the CLI; they
> Daniel> sort-of work for other front-ends, and print a warning to that
> Daniel> effect.  Documentation included.  These are pretty much how
> Daniel> Tom originally did them:
> 
> You'll hate to hear this, but I ended up rewriting the patch to be a
> `transcript' command.  The follow-on discussion to my original patch
> convinced me that the names ">" and ">>" weren't that great.  Also,
> going this route let me remove some of the hacks in cli/.
> 
> The new usage I implemented is:
> 
>     transcript > FILE
>     transcript >> FILE
>     transcript | COMMAND

I don't like this syntax very much.  It looks too much like dumping the
output of a command ("transcript") to the file, not like a redirection
for the future output.  If I were in hard-core shell mode this week I'd
suggest "exec > FILE" but I don't really like that one much either...

Also - is piping to a command actually useful?

> I never submitted my rewrite since I hadn't addressed the one
> remaining problem, namely teeing.  I can send it if you want it.
> 
> Daniel> tee file
> Daniel> tee -a file
> 
> Maybe tee should be the default?  My experiments using the transcript
> code indicated to me that it is hard to use gdb when you don't see the
> output...

Hmm...  How do you feel about:

	transcript [-append] FILE
	tee [-append] FILE

Where transcript replaces ">" and ">>"?

-- 
Daniel Jacobowitz                           Carnegie Mellon University
MontaVista Software                         Debian GNU/Linux Developer


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]