Path: utzoo!utgpu!news-server.csri.toronto.edu!rpi!usc!cs.utexas.edu!sun-barr!newstop!exodus!warp.Eng.Sun.COM!rock From: rock@warp.Eng.Sun.COM (Bill Petro) Newsgroups: comp.mail.mush Subject: Re: setting up a list from pick? Message-ID: <13561@exodus.Eng.Sun.COM> Date: 18 May 91 18:25:35 GMT References: <4064@island.COM> Sender: news@exodus.Eng.Sun.COM Lines: 45 daniel@island.COM (Daniel Smith "innovation, not litigation...") writes: > Consider these two cmd's: ># pick from >cmd pf "pick -f \!*; pick -f \!* | set m" ># echo message list that matched >cmd em 'echo $m' > I say "pf gumby" and see the list of headers of messages from gumby. >I can then say "em" and see the list of article numbers that my search >found. I would like to get this same behavior without running pick twice. >I like seeing the headers scroll by as pick does its work, but (at least >in mush, perhaps not in Zmail) the list of matches isn't automatically >stashed anywhere, is it? > My goal would be to cmd pick to something that always gives me >a var to echo out, without doing the initial search twice... > Daniel pick leaves it's output msg_list in an undocumented variable called $output. You could exploit that variable if you like. I do in this way: I do a pick on some subject: pick -s boffo After I've seen the list of headers, and decide I'd like to look at the content of the messages, I do this: $output | $pager I even have it bound to a keybinding, ^Xp: bind-macro '\CXp' ':$output | $pager\n' -- Bill Petro {decwrl,hplabs,ucbvax}!sun!Eng!rock "UNIX for the sake of the kingdom of heaven" Matthew 19:12