andy@coma.UUCP (Andreas Lampen) (05/09/90)
Please send me your most favourite (sophisticated, cryptic, funny) pipe ! I want to open the list with a quite common one: soelim foo.ms | refer -sAD -l4,2 | pic | troff -Talw -ms | tps | lpr -Plw and a cross machine pipe: tar cf - | dd bs=20k | rsh coma "cd blubber; dd bs=20k | tar xf -" We are currently working on a concept for an object oriented shell for UNIX and (of course) ran into difficulties when trying to model the pipe mechanism. We came up with a first idea but soon found an example where this didn't work ... . Now, this inquiry shall set up a list of pipes that helps us to validate our ideas. Additionally, I think such a list will be quite interesting for UNIX users. I will post a summary anyway. Thanks in advance, Andy -- ---- Andreas Lampen, Tech. Univ. Berlin andy@coma.cs.tu-berlin.de
merlyn@iwarp.intel.com (Randal Schwartz) (05/10/90)
In article <690@coma.UUCP>, andy@coma (Andreas Lampen) writes: | tar cf - | dd bs=20k | rsh coma "cd blubber; dd bs=20k | tar xf -" I would use: tar cf - . | dd obs=20k | rsh coma "cd blubber && tar xf -" The second dd contributes nothing. The "&&" prevents you from extracting a whole mess of stuff in the wrong directory should you "fat-finger" the target directory. (Leaving the '.' off the tar sends an empty archive... you gotta send at least *something*. :-) I also usually leave off the first dd, because tar writes its stuff 20*512 bytes at a time anyway. If I'm nosy, it comes out as: tar cf - . | rsh coma "cd blubber && tar xvf -" so I can get a progress report. Run it in a separate window (GNU Emacs or bitmap window, take yer pick). Just another tar baby, -- /=Randal L. Schwartz, Stonehenge Consulting Services (503)777-0095 ==========\ | on contract to Intel's iWarp project, Beaverton, Oregon, USA, Sol III | | merlyn@iwarp.intel.com ...!any-MX-mailer-like-uunet!iwarp.intel.com!merlyn | \=Cute Quote: "Welcome to Portland, Oregon, home of the California Raisins!"=/
bengsig@oracle.nl (Bjorn Engsig) (05/25/90)
In article <690@coma.UUCP> andy@coma.UUCP (Andreas Lampen) writes: |Please send me your most favourite (sophisticated, cryptic, funny) pipe ! Neither sophisticated, cryptic or funny, but often useful: $ make foo make: don't know how to make `foo' $ make -n all | grep foo | sh -x -- Bjorn Engsig, Domain: bengsig@oracle.nl, bengsig@oracle.com Path: uunet!mcsun!orcenl!bengsig
bush@evax.arl.utexas.edu (Joe Bush) (05/26/90)
Here is one I concocted to search for key words in include files: echo -n "key=";set kw=`line`;find /usr/include/. /sys/. -name \*.h -print | xargs hgrep "$kw" {} I keep a file of such one-liners like the one above (file of one line pipe-programs is named $HOME/.syscom) and have the following line in my .cshrc: alias g 'set j=`cat ${home}/.syscom|wc -l`;source -h ${home}/.syscom; history | tail -"$j"' Then when I enter "g" from the keyboard, my csh history mechanism gets primed for easy execution. I find it quite handy... - Joe -- bush@evax.arl.utexas.edu Vax Systems Manager (817) 273 - 3333 CSE Dept. UT-Arlington Office Rm 221 EB2 403 South Cooper P.O. Box 19015 Arlington, Texas 76019