sort with a tab as separator
Sean Legassick
asrap at warwick.ac.uk
Fri Aug 31 03:54:26 AEST 1990
In article <1990Aug19.051237.27735 at midway.uchicago.edu> phd_ivo at gsbacd.uchicago.edu writes:
=In article <13617 at smoke.BRL.MIL>, gwyn at smoke.BRL.MIL (Doug Gwyn) writes...
=
=+So get a real shell:
=+ $ echo ' ' | od -c
=+ 0000000 \t \n
=
=On a NeXT improved csh (and presumably on some other shells), the following
=works:
=
= sort -t\^V^I
=
=that is, the tab must be quoted twice: once with the backslash, and then with
=the ^V (control-V) to not substitute spaces.
=
Okay, csh is seriously f*cked. However:
csh% echo ' ' | od -c
0000000 \t \n
0000002
tcsh% echo '^ ' | od -c (NB: ^V needed before TAB as TAB has special
meaning in tcsh)
0000000 \t \n
0000002
So *csh may not be a 'real shell' but this I'm afraid it does do (Sun-4,
SunOs 4.0.3).
---------------------------------------------------------------------------
Sean Legassick, cuuee at uk.ac.warwick.cu "Improbability factor of one
Computing Services asrap at uk.ac.warwick.cu to one. We have normality.
University of Warwick Anything you still can't
(the walking C obfuscator!) handle is your own problem."
More information about the Comp.unix.questions
mailing list