Mailinglist Archive: opensuse (1696 mails)
| < Previous | Next > |
Re: [opensuse] should we keep the commandline pipe tradition?
- From: Adam Tauno Williams <awilliam@xxxxxxxxxxxxx>
- Date: Mon, 27 Jul 2009 12:05:28 -0400
- Message-id: <1248710728.5867.40.camel@linux-m3mt>
On Mon, 2009-07-27 at 23:24 +0800, Zhang Weiwu wrote:
Yes, but it also has the same shortcomings it always had.
But I don't even have a /dev/midi. Part of this may be because
the /dev/ filesystem is such a pain. Devices aren't files and treating
them as such is just odd, you end up with lots of weird device specific
ioctl() calls and on systems with many devices or devices that change
frequently the old /dev/xyz0 ... /dev/xyz9999 also gets clunky. So the
above may not have anything to do with pipe-love but just the realities
of modern device management.
Which might be making temp files anyway; now they are just asking you to
do it. A pipe is a read only (or write only) sequential stream, you
can't seek it, which makes processing some types of data a pain. Also
piping as described aggregates all the data (BLOBs really in this case)
and perhaps the utility needs to now the start and end of each BLOB
which the process of piping has obscured.
It is used a lot. But, at the risk of being flamed like crazy, the UNIX
pipe & shell certainly does seem primitive next to object piping
supported in Microsoft Powershell (and some other proprietary known
CLIs). Sadly I'm not aware of any Open Source OO shells and PASH
<http://pash.sourceforge.net/> seems dead in the water. Due to so much
of the modern BLOB oriented (non-text) data and network oriented stuff I
find myself using Python or something like Boo way more than the UNIX
shell for both scripting and interactive work. If you want to work with
files and information I certainly wouldn't go to shell anymore except
for really basic stuff. In an OO shell you can tread an image like an
image, a mail message like a mail message, etc... and not have to hack
around so much.
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
Hi. I haven't been using commandline extensively for some years, and
when I come back to Linux, I was surprised to see GUI software being
developed so fast and so well on Linux (and feel happy about it).
However I wonder if current commandlin isn't as useful as was.
Yes, but it also has the same shortcomings it always had.
$ timidity -AD # put to daemon mode
$ aconnect 16:0 128:0
# 16:0 is another way to represent /dev/midi
# while 128:0 is the virtual device that generates sound
But I don't even have a /dev/midi. Part of this may be because
the /dev/ filesystem is such a pain. Devices aren't files and treating
them as such is just odd, you end up with lots of weird device specific
ioctl() calls and on systems with many devices or devices that change
frequently the old /dev/xyz0 ... /dev/xyz9999 also gets clunky. So the
above may not have anything to do with pipe-love but just the realities
of modern device management.
Another example: when I wanted to join multiple TIFF images into a
single multi-page tiff image, I thought I could do this:
$ tiffcat < page-1.tiff page-2.tiff page-3.tiff page-4.tiff > pages.tiff
And I was told no. The right way to do it is:
$ tiffcp page-1.tiff page-2.tiff page-3.tiff page-4.tiff pages.tiff
The problem of tiffcp is I have to use the temporary files, otherwise I
could pipe the output of the command that generated these page-?.tiff,
like this:
$ (cmd1; cmd2; cmd3) | tiffcp > pages.tiff
Which might be making temp files anyway; now they are just asking you to
do it. A pipe is a read only (or write only) sequential stream, you
can't seek it, which makes processing some types of data a pain. Also
piping as described aggregates all the data (BLOBs really in this case)
and perhaps the utility needs to now the start and end of each BLOB
which the process of piping has obscured.
I was wondering if pipe is now being used less as it was used to be or
should be, and is this something good or bad?
It is used a lot. But, at the risk of being flamed like crazy, the UNIX
pipe & shell certainly does seem primitive next to object piping
supported in Microsoft Powershell (and some other proprietary known
CLIs). Sadly I'm not aware of any Open Source OO shells and PASH
<http://pash.sourceforge.net/> seems dead in the water. Due to so much
of the modern BLOB oriented (non-text) data and network oriented stuff I
find myself using Python or something like Boo way more than the UNIX
shell for both scripting and interactive work. If you want to work with
files and information I certainly wouldn't go to shell anymore except
for really basic stuff. In an OO shell you can tread an image like an
image, a mail message like a mail message, etc... and not have to hack
around so much.
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx
| < Previous | Next > |