[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
split --filter, nearly ready
From: |
Jim Meyering |
Subject: |
split --filter, nearly ready |
Date: |
Sat, 30 Apr 2011 15:31:01 +0200 |
Here's what I have so far.
One remaining task is to write the ChangeLog entry for
Karl's initial change.
[1/8] split: accept new output --filter option
[2/8] split: remove short-named -f option; improve diagnostics
[3/8] split: add tests
[4/8] split: update NEWS
[5/8] split: mark a string for translation
[6/8] strip: style: use braces around 1-stmt-but-multi-line
[7/8] split: don't rely on knowledge that INT_BUFSIZE_BOUND <=
[8/8] doc: document split's new --filter=CMD option
b/NEWS | 10 ++
b/doc/coreutils.texi | 24 +++++
b/src/split.c | 211 +++++++++++++++++++++++++++++++++++++++++++++------
b/tests/Makefile.am | 1
b/tests/split/filter | 41 +++++++++
src/split.c | 42 ++++++----
6 files changed, 287 insertions(+), 42 deletions(-)
I've already merged a few small changes into Karl's initial 1/8,
and will merge others (probably 2, 5, 6, 7), but have left them
separate for now to facilitate review.
One oddity that I have not documented is how --elide-empty-files
works with --filter, but I did add a test to demonstrate
the existing behavior:
# Show how --elide-empty-files works with --filter:
# split does not run the command (and effectively elides the file)
# only when the output to that command would have been empty.
split -e -n 10 --filter='xz > $FILE.xz' /dev/null || fail=1
stat x?? 2>/dev/null && fail=1
Feedback welcome.
- split --filter, nearly ready,
Jim Meyering <=
- [PATCH 4/8] split: update NEWS, Jim Meyering, 2011/04/30
- [PATCH 7/8] split: don't rely on knowledge that INT_BUFSIZE_BOUND <= SIG2STR_MAX, Jim Meyering, 2011/04/30
- [PATCH 3/8] split: add tests, Jim Meyering, 2011/04/30
- [PATCH 6/8] strip: style: use braces around 1-stmt-but-multi-line blocks, Jim Meyering, 2011/04/30
- [PATCH 2/8] split: remove short-named -f option; improve diagnostics, Jim Meyering, 2011/04/30
- [PATCH 5/8] split: mark a string for translation, Jim Meyering, 2011/04/30
- [PATCH 8/8] doc: document split's new --filter=CMD option, Jim Meyering, 2011/04/30