Jim Meyering ha scritto:
Francesco Montorsi <[EMAIL PROTECTED]> wrote:
...
Finally copyright stuff should be okay.
So, I repost the patch ;)
Thanks for the ping.
There is at least one patch in the queue ahead of this.
One thing you can do to accelerate the process is to add
a few tests.
ok, I'll wait my turn :)
Thanks for being patient.
Did you add any tests?
yes, I created a small test looking at tests/ls/noarg...
I attach it to this mail but I don't know if the test is good enough...
Francesco
#!/bin/sh
# be sure that ls --group-directories-first works as expected
if test "$VERBOSE" = yes; then
set -x
ls --version
fi
pwd=`pwd`
tmp=groupdirs.$$
trap 'status=$?; cd $pwd; rm -rf $tmp && exit $status' 0
trap '(exit $?); exit' 1 2 13 15
framework_failure=0
mkdir $tmp || framework_failure=1
cd $tmp || framework_failure=1
mkdir -p b c e x y z || framework_failure=1
touch a d f || framework_failure=1
ln -s d dsymlink || framework_failure=1
# files should have been listed at the end...
cat > exp <<\EOF || framework_failure=1
b
c
e
x
y
z
a
d
dsymlink
exp
f
out
EOF
if test $framework_failure = 1; then
echo 'failure in testing framework'
(exit 1); exit 1
fi
fail=0
ls -1 --group-directories-first > out || fail=1
cmp out exp || fail=1
test $fail = 1 && diff out exp 2> /dev/null
# files should have been listed at beginning this time
cat > exp <<\EOF
z
y
x
e
c
b
out
f
exp
dsymlink
d
a
EOF
ls -1 --group-directories-first --reverse > out || fail=1
cmp out exp || fail=1
test $fail = 1 && diff out exp 2> /dev/null
(exit $fail); exit $fail
_______________________________________________
Bug-coreutils mailing list
Bug-coreutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-coreutils