Re: why does "cut" print fields in original order?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Tony Nelson wrote:
> This all rather begs the question of what tool to use after cut in
> order to reorder the fields?

Why use anything after cut when you can more easily just replace cut
for this task?

> Don't pretend the answer is sed or awk, or their ilk.

How would I be pretending about this output?

awk -F : '{print $7, $1}' /etc/passwd
/bin/bash root
/sbin/nologin bin
/sbin/nologin daemon
...

-- 
Todd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The triumph of persuasion over force is the sign of a civilized
society.
    -- Mark Skousen

Attachment: pgpERVQlmLkHD.pgp
Description: PGP signature


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux