Re: PATCH: relpath

2011-12-11 Thread Pádraig Brady
FYI I'm not forgetting about this. This week I'll be travelling with work, but I intend to tackle this early the following week. cheers, Pádraig.

Re: [PATCH] stat,tail: recognize new local FS type: pipefs

2011-12-26 Thread Pádraig Brady
On 12/26/2011 03:50 PM, Jim Meyering wrote: --- a/src/stat.c +++ b/src/stat.c +case S_MAGIC_PIPEFS: /* 0x50495045 remote */ + /* FIXME: change syntax or add an optional attribute like inotify:no. + The above is labeled as remote so that tail always uses polling, +

Re: [PATCH] tail: avoid theoretically undefined behavior

2011-12-28 Thread Pádraig Brady
On 12/28/2011 05:56 PM, Jim Meyering wrote: Can anyone name a real system on which forming a pointer like this, buffer + (size_t)(-1) actually provokes a trap or some other real problem? I don't know of particular hardware where this would trap (alpha can be configured to trap on integer

Re: [PATCH] tail: avoid theoretically undefined behavior

2011-12-28 Thread Pádraig Brady
On 12/28/2011 09:30 PM, Jim Meyering wrote: Pádraig Brady wrote: On 12/28/2011 05:56 PM, Jim Meyering wrote: Can anyone name a real system on which forming a pointer like this, buffer + (size_t)(-1) actually provokes a trap or some other real problem? I don't know of particular hardware

Re: PATCH: relpath

2012-01-02 Thread Pádraig Brady
On 12/31/2011 11:27 AM, Jim Meyering wrote: Pádraig Brady wrote: ... Reading only the documentation for --relative-base=FILE, I am not sure how it works: `--relative-base=FILE' Ensure both the `--relative-to' and processed files are subdirectories of FILE, or otherwise output

Re: bug#10363: df vs. long-named /dev/disk/by-uuid/... file system device names

2012-01-02 Thread Pádraig Brady
On 01/02/2012 05:34 PM, Jim Meyering wrote: Jim Meyering wrote: ... + char *dev_name = xstrdup (disk); + char *resolved_dev; + + /* On some systems, dev_name is a long-named symlink like + /dev/disk/by-uuid/828fc648-9f30-43d8-a0b1-f7196a2edb66 pointing + to a much shorter and

Re: realpath options

2012-01-02 Thread Pádraig Brady
On 01/02/2012 08:06 PM, Bruno Haible wrote: Pádraig Brady wrote in http://lists.gnu.org/archive/html/bug-gnulib/2011-12/msg00237.html: This is for use in a proposed coreutils `realpath` command. Specifically by these options: -L, --logicalresolve `..' components before

Re: realpath options

2012-01-03 Thread Pádraig Brady
On 01/03/2012 12:30 AM, Bruno Haible wrote: Pádraig Brady wrote: To me realpath is conceptually (cd; pwd), so I used the -L and -P options as defined by POSIX for cd. Makes good sense, yes. I considered using --no-dereference, but while the symlinks in a path are not expanded

Re: bug#10363: df vs. long-named /dev/disk/by-uuid/... file system device names

2012-01-03 Thread Pádraig Brady
On 01/03/2012 03:58 PM, Jim Meyering wrote: diff --git a/NEWS b/NEWS + df, with no non-option argument and recent enough kernel/tools, would + print a long UUID-including file system name, pushing second and subsequent + columns far to the right. Now, when that long name refers to a

Re: new snapshot available: coreutils-8.14.116-1e18d

2012-01-03 Thread Pádraig Brady
On 01/03/2012 04:29 PM, Jim Meyering wrote: FYI, here's a snapshot of what will soon be coreutils-8.15, expected on Thursday or Friday. coreutils snapshot: http://meyering.net/cu/coreutils-ss.tar.xz 5.2 MB sort-continue was the only failure on: $ uname -mi; sw_vers i386 Macmini4,1

Re: new snapshot available: coreutils-8.14.116-1e18d

2012-01-03 Thread Pádraig Brady
On 01/03/2012 04:29 PM, Jim Meyering wrote: FYI, here's a snapshot of what will soon be coreutils-8.15, expected on Thursday or Friday. coreutils snapshot: http://meyering.net/cu/coreutils-ss.tar.xz 5.2 MB misc/stty was the only failure on: $ uname -a Linux deluxe

bug#10430: coreutils-8.14.116-1e18d: make distcheck failure on Debian (one test failed)

2012-01-04 Thread Pádraig Brady
On 01/04/2012 02:12 PM, Stefano Lattarini wrote: The only failed test was `misc/timeout-group'. This is either a race in the test or a bug in timeout, neither of which I can see. Your system is running 2.6.30-2-686 SMP Does this fail all the time? (cd tests make check

Re: [PATCH] Support for --size in du

2012-01-04 Thread Pádraig Brady
On 10/11/2011 08:00 PM, Jakob Truelsen wrote: On Tue, Oct 11, 2011 at 4:55 PM, Voelker, Bernhard bernhard.voel...@siemens-enterprise.com wrote: Jakob Truelsen wrote: On Tue, Oct 11, 2011 at 4:19 PM, Voelker, Bernhard bernhard.voel...@siemens-enterprise.com wrote: Jakob Truelsen wrote: I

Re: coreutils-8.14.116-1e18d on Linux/HPPA

2012-01-04 Thread Pádraig Brady
On 01/04/2012 10:59 PM, Bruno Haible wrote: http://meyering.net/cu/coreutils-8.14.116-1e18d.tar.xz On Linux/hppa: FAIL: misc/timeout-parameters The test suite log shows this execution log: + test 125 = 125 + timeout 4294967296 sleep 0 + test 124 = 0 + fail=1 ++ expr 4294967295 /

Re: factor help message improvement

2012-01-04 Thread Pádraig Brady
On 09/22/2011 05:39 PM, Loïc Le Loarer wrote: Hi All, I would like to propose a small improvement to factor help message: indicate factor capabilities and in particular maximum input size. As it depends on how factor has been compiled (with or without GMP library), I propose the attached

Re: coreutils-8.14.116-1e18d on Linux/HPPA

2012-01-04 Thread Pádraig Brady
On 01/05/2012 12:39 AM, Bruno Haible wrote: Hi Pádraig, Hopefully the attached avoids this. Your patch avoids the first 3 fail=1 occurrences, but not the fourth one: + timeout 2.34e+5d sleep 0 + test 124 = 0 + fail=1 Oops right. But is this really the desirable workaround? Do

Re: coreutils-8.14.116-1e18d on Linux/HPPA

2012-01-05 Thread Pádraig Brady
On 01/05/2012 04:05 AM, Bruno Haible wrote: Pádraig Brady wrote: No, time_t is typedefed to 'long int' (32-bit but signed) on this platform. Right, so if time_t is changed to 64 bit there in future, the test would be too restrictive? time_t cannot be changed to 64-bit without breaking

Re: coreutils-8.14.116-1e18d on NetBSD 5.1 - split bug

2012-01-05 Thread Pádraig Brady
On 01/05/2012 02:32 AM, Bruno Haible wrote: http://meyering.net/cu/coreutils-8.14.116-1e18d.tar.xz On NetBSD 5.1/x86, I get this test failure in particular: FAIL: split/l-chunk === split: /dev/zero: No such file or directory stat: cannot stat `x*': No such file or

Re: New coreutil suggestion - tableize

2012-01-07 Thread Pádraig Brady
On 11/27/2011 05:30 PM, Guillaume Kielwasser wrote: Thanks Pádraig for your instructive input! Hmm, I wonder would it be worth augmenting `column -t` from util-linux to add a --border option and also detect number cols and auto right align? I guess a --header option would be useful too. I

Re: begin updating for new quoting style

2012-01-07 Thread Pádraig Brady
On 01/07/2012 04:20 PM, Jim Meyering wrote: - fprintf (stderr, _(Try `%s --help' for more information.\n), program_name); + fprintf (stderr, _(Try '%s --help' for more information.\n), program_name); Looks good. Those quote always annoyed me, having never seen them rendered

Re: Can dd cross device boundaries?

2012-01-09 Thread Pádraig Brady
On 01/08/2012 08:42 PM, Francois Marier wrote: Hi, (I'm guessing this might be the right list, but feel free to let me know if there's a better one.) It looks like I've hosed one of my hard drives through some clueless use of the dd command (as root of course) and I'd like to understand

bug#10467: BUG Report: coreutils 64bit Build on Solaris 10

2012-01-09 Thread Pádraig Brady
On 01/09/2012 08:24 PM, Jim Meyering wrote: gfpmtipb GFP IP App ID wrote: coreutils-8.11 ... FAIL: misc/env-null (exit: 1) = ... + fail=1 + env -i

Re: [PATCH] maint: adjust formatting of certain continued strings

2012-01-11 Thread Pádraig Brady
On 01/10/2012 06:00 PM, Jim Meyering wrote: - format = xasprintf (%s%s, format, _(\ -Access: %x\n\ -Modify: %y\n\ -Change: %z\n\ - Birth: %w\n\ -)); + format = xasprintf (%s%s, format, + _(Access: %x\n +Modify:

[PATCH] maint: cleanup an extraneous version output in a test

2012-01-25 Thread Pádraig Brady
commit 14a1e3ea837f1453423ae101e3f04103d4fd8910 Author: Pádraig Brady p...@draigbrady.com Date: Wed Jan 25 23:13:58 2012 + maint: cleanup an extraneous version output in a test * test/misc/stdbuf: Fixup the minor copy paste issue introduced in commit ff7f0ff8 diff --git

parallel make issues

2012-01-25 Thread Pádraig Brady
There are some issues with the following, with sometimes tests being skipped and/or sometimes output being misaligned. (cd tests make -j2 check TESTS=misc/stty misc/stdbuf misc/stat-birthtime misc/stty-row-col VERBOSE=yes) That's because gnu make in parallel mode, will give a single one of its

[PATCH] scripts: allow empty commit messages abort the commit

2012-01-25 Thread Pádraig Brady
: Pádraig Brady p...@draigbrady.com Date: Thu Jan 26 00:55:55 2012 + scripts: allow empty commit messages abort the commit * scripts/git-hooks/commit-msg: Validate empty commit messages, so that git will abort the commit as normal. diff --git a/scripts/git-hooks/commit-msg b/scripts

Re: parallel make issues

2012-01-26 Thread Pádraig Brady
On 01/26/2012 09:26 AM, Jim Meyering wrote: I'm happy to let the tests skip when necessary, or even to disrupt parallel build output a little, but if we fix it, using expect or python/perl-expect would be my preference. Yes, it's not a big issue. I'm happy to leave as is rather than adding

pr -S option arg

2012-01-30 Thread Pádraig Brady
I notice that `pr -S` takes an optional arg, but the docs say it's required. Should I fix the docs or the code? cheers, Pádraig.

bug#10735: chmod +x file

2012-02-06 Thread Pádraig Brady
tags 10735 notabug On 02/06/2012 02:23 PM, francky.l...@telenet.be wrote: Hello, I perform the following: ubuntu@ubuntu-VirtualBox:~/.gvfs/account on stockholm/Documents/03 professional/structured_documentation$ ls -l doc/filters_for_this_document -rwx-- 1 ubuntu ubuntu 98

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-06 Thread Pádraig Brady
On 02/06/2012 02:01 PM, Jérémy Compostella wrote: Pádraig, all, I took into account general comments on my commits. I attached the improved patch for feature. Improvements are: - Add by file description, - I put back accents on my name (Jérémy instead of Jeremy), Great thanks. Hmm,

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-06 Thread Pádraig Brady
On 02/06/2012 03:24 PM, Jérémy Compostella wrote: Hmm, shouldn't there be a seek_bytes param too for consistency? That was effectively my first mail question. As you talk about it in your explanation addition in coreutils.texi I guess I should start implementing it ? I think so. Note it

Re: uniq --accumulate

2012-02-07 Thread Pádraig Brady
On 02/07/2012 03:56 PM, Peng Yu wrote: Hi, Suppose that I have a table of the following, where the last column is a number. I'd like to accumulate the number of rows that are the same for all the remaining columns. A 1 A 3 X 2 X 3 Y 3 The result will be the following. Although this

bug#10561: stat unclear about size on disk and type of blocks discussed

2012-02-07 Thread Pádraig Brady
On 02/07/2012 06:26 PM, Filipus Klutiero wrote: Hi Pádraig, On 2012-01-20 19:03, Pádraig Brady wrote: On 01/20/2012 05:47 PM, Filipus Klutiero wrote: Hi Pádraig and Jim, On 2012-01-20 09:15, Pádraig Brady wrote: On 01/20/2012 02:03 PM, Jim Meyering wrote: Pádraig Brady wrote

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-07 Thread Pádraig Brady
On 02/07/2012 06:25 PM, Jérémy Compostella wrote: On 02/06/2012 03:24 PM, Jérémy Compostella wrote: Hmm, shouldn't there be a seek_bytes param too for consistency? That was effectively my first mail question. As you talk about it in your explanation addition in coreutils.texi I guess I

Re: [PATCH] test: expose recent gnulib canonicalize bug

2012-02-08 Thread Pádraig Brady
On 02/07/2012 12:33 AM, Eric Blake wrote: https://lists.gnu.org/archive/html/bug-gnulib/2012-02/msg00038.html detailed a couple of bugs in gnulib's canonicalize that were visible through coreutils' readlink, but only on systems where // is distinct from /. This particular test assumes that

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-08 Thread Pádraig Brady
On 02/08/2012 03:14 PM, Jérémy Compostella wrote: That leads onto the only other possible implementation I suppose. I.E. since we don't need to specify skip and skip_bytes together, the option value could select between each mode. I.E. skip=2 = skip2 blocks, skip=2b = skip 1024

Re: [PATCH] test: expose recent gnulib canonicalize bug

2012-02-08 Thread Pádraig Brady
On 02/08/2012 04:14 PM, Eric Blake wrote: Question before I push: Right now, we have: tests/readlink/can-{e,f,m} tests/readlink/rl-1 tests/misc/readlink-fp-loop This feels inconsistent; should we be consolidating all readlink-related tests into the same directory, and if so, which

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-09 Thread Pádraig Brady
On 02/09/2012 11:32 AM, Jim Meyering wrote: @@ -2918,10 +2935,17 @@ gobble_file (char const *name, enum filetype type, ino_t inode, { bool have_selinux = false; bool have_acl = false; - int attr_len = (do_deref - ?

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-09 Thread Pádraig Brady
On 02/09/2012 02:17 PM, Jim Meyering wrote: Pádraig Brady wrote: On 02/09/2012 11:32 AM, Jim Meyering wrote: Technically, we could probably exempt all files on that device, but ... So you avoid symlinks as they can point outside the device. Unfortunately so can bind mounts, so you probably

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-09 Thread Pádraig Brady
On 02/09/2012 09:17 PM, Sven Breuner wrote: Jim Meyering wrote on 02/09/2012 03:17 PM: Pádraig Brady wrote: On 02/09/2012 11:32 AM, Jim Meyering wrote: Technically, we could probably exempt all files on that device, but ... So you avoid symlinks as they can point outside the device

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-10 Thread Pádraig Brady
On 02/10/2012 04:21 PM, Jérémy Compostella wrote: Pádraig, others, First, I added the missing seek_bytes feature. Second, I re-wrote the patch in order to replace the _bytes operands by the corresponding input/output flags. Finally, I added some tests to check the new seek_bytes flag. I

Re: sort complexity on nearly sorted input

2012-02-11 Thread Pádraig Brady
On 02/11/2012 04:20 PM, Peng Yu wrote: Hi, I assume the time complexity of 'sort' is log N, where N is the input size. But I'm not familiar with 'sort' enough to tell the complexity of sorting a nearly sorted input. Suppose that I have a listed of N numbers, there only k numbers (k N,

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-11 Thread Pádraig Brady
On 02/12/2012 01:01 AM, Sven Breuner wrote: Pádraig Brady wrote on 02/10/2012 02:03 AM: On 02/09/2012 09:17 PM, Sven Breuner wrote: Current git version patched... $ time ~/tmp/ls-8.15.34-31eee_patched -l/dev/null real0m21.254s user0m0.565s sys 0m2.496s $ strace -c ~/tmp/ls

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-11 Thread Pádraig Brady
On 02/10/2012 04:57 PM, Pádraig Brady wrote: On 02/10/2012 04:21 PM, Jérémy Compostella wrote: Pádraig, others, First, I added the missing seek_bytes feature. Second, I re-wrote the patch in order to replace the _bytes operands by the corresponding input/output flags. Finally, I added some

Re: Paste more than two files

2012-02-12 Thread Pádraig Brady
On 02/12/2012 02:36 AM, goodman@gmail.com wrote: Hi Coreutils, I posted to the list about a month ago and haven't gotten any response. Perhaps it got overlooked because of the holidays (or post-holiday email glut), so I'm reposting it: --- Hello, I fairly recently discovered the

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-13 Thread Pádraig Brady
On 02/13/2012 07:50 AM, Bernhard Voelker wrote: On 02/10/2012 05:21 PM, Jérémy Compostella wrote: Sorry, this is a bit late, but I have 2 notes about the new dd/bytes test: diff --git a/tests/dd/bytes b/tests/dd/bytes new file mode 100755 index 000..6038742 --- /dev/null +++

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-13 Thread Pádraig Brady
On 02/13/2012 10:13 AM, Bernhard Voelker wrote: On 02/13/2012 11:00 AM, Pádraig Brady wrote: On 02/13/2012 07:50 AM, Bernhard Voelker wrote: On 02/10/2012 05:21 PM, Jérémy Compostella wrote: Sorry, this is a bit late, but I have 2 notes about the new dd/bytes test: diff --git a/tests

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-13 Thread Pádraig Brady
I've just noticed a couple of edge case issues. The first hunk is for when not doing I/O, ftruncate() should be on the full size. The second, will not invalidate cache for the whole file, if 0 count ibs cheers, Pádraig. --- a/src/dd.c +++ b/src/dd.c @@ -2170,7 +2170,7 @@ main (int argc, char

Re: dd: add 'skip_bytes' and 'count_bytes' operands

2012-02-13 Thread Pádraig Brady
On 02/13/2012 02:28 PM, Bernhard Voelker wrote: On 02/13/2012 02:09 PM, Pádraig Brady wrote: BTW: shouldn't echo abcdefghijklm | src/dd bs=5 seek=8 oflag=seek_bytes receive EPIPE? When run on a terminal, dd waits in read() forever. True. That's because we try to seek using read

Re: Adding humanize_number to coreutiles?

2012-02-13 Thread Pádraig Brady
On 02/13/2012 03:45 AM, Peng Yu wrote: 2012/2/7 Pádraig Brady p...@draigbrady.com: On 02/07/2012 03:36 AM, Peng Yu wrote: Hi, Several commands in coreutils have the -h option. I'm wondering whether anybody in the develop team also thinks that it is worthwhile to export it as a standalone

Re: join on multiple field

2012-02-14 Thread Pádraig Brady
On 02/13/2012 01:54 PM, Peng Yu wrote: Can't you already do this with awk? This is not a very useful comment. Take things on this list as discussion, rather than a mandate. We're all very open here. Everything that coreutils do can be done with some other software. Since 'join' can do 1

Re: [PATCH]: add an option for quiet copy operations

2012-02-16 Thread Pádraig Brady
On 02/16/2012 07:21 AM, Guido Trentalancia wrote: Hello. I am writing to propose a simple patch for review. The patch adds an option -q or --quiet to cp, mv and install so that they can support quiet operation on missing SOURCE files. Such behavior might be useful for example when using

Re: [PATCH]: add an option for quiet copy operations

2012-02-16 Thread Pádraig Brady
On 02/16/2012 02:01 PM, Pádraig Brady wrote: On 02/16/2012 07:21 AM, Guido Trentalancia wrote: Hello. I am writing to propose a simple patch for review. The patch adds an option -q or --quiet to cp, mv and install so that they can support quiet operation on missing SOURCE files

Re: bug#9085: 'split' feature request: an option to uses e.g. '.001' as first suffix.

2012-02-16 Thread Pádraig Brady
On 02/16/2012 09:30 PM, Jérémy Compostella wrote: Pádraig, all, I rebased my branch for this feature and make the syntax-check success. I attached the new patch which I hope will satisfy you. Feel free to comment it, I will take into account whatever you want. Thanks for continuing with

[PATCH] doc: fix a typo about seek_bytes in NEWS

2012-02-17 Thread Pádraig Brady
* NEWS: s/count_bytes/seek_bytes/2 --- NEWS |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/NEWS b/NEWS index 2080790..7973b55 100644 --- a/NEWS +++ b/NEWS @@ -4,7 +4,7 @@ GNU coreutils NEWS-*- outline -*- ** New features - dd

Re: bug#9085: 'split' feature request: an option to uses e.g. '.001' as first suffix.

2012-02-17 Thread Pádraig Brady
On 02/17/2012 05:56 PM, Jérémy Compostella wrote: I attached the new patch. I tried to make it as simple as possible but feel free to comment. Thanks! I just grouped the operations in next_file_name() a little for clarity, tweaked a couple of strings, and pushed. cheers, Pádraig.

Re: bug#6554: [PATCH] split: Additional suffix for split (bug#6554)

2012-02-19 Thread Pádraig Brady
On 02/19/2012 12:54 PM, Jérémy Compostella wrote: Pádraig, I replaced --suffix with --additional-suffix and made some cleaning. Feel free to comment the attached patch. Logic is perfect again. I adjusted the help output a little like: - -a, --suffix-length=N use suffixes of length N

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-20 Thread Pádraig Brady
On 02/20/2012 02:06 AM, Sven Breuner wrote: Pádraig Brady wrote on 02/20/2012 12:54 AM: On 02/19/2012 10:22 PM, Sven Breuner wrote: Is there maybe another check that could be used to find out if selinux is disabled? (e.g. is_selinux_enabled(3) ) I'm not sure you could use that. Even though

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-20 Thread Pádraig Brady
On 02/19/2012 05:00 PM, Jim Meyering wrote: Pádraig Brady wrote: Also I was a bit surprised to see EBUSY and ENOENT in errno_unsupported(). Can one assume there are no other attributes on a device if you get those? I added those to align with ACL_NOT_WELL_SUPPORTED from lib/acl-internal.h

Re: [PATCH v2] ln: add the --relative option

2012-02-23 Thread Pádraig Brady
On 02/23/2012 09:28 PM, Eric Blake wrote: On 02/23/2012 12:50 PM, har...@redhat.com wrote: From: Harald Hoyer har...@redhat.com With the --relative --symbolic options, ln computes the relative symbolic link for the user. So, ln works just as cp, but creates relative symbolic links instead

Re: [PATCH v2] ln: add the --relative option

2012-02-24 Thread Pádraig Brady
On 02/24/2012 07:58 AM, Voelker, Bernhard wrote: har...@redhat.com wrote: With the --relative --symbolic options, ln computes the relative symbolic link for the user. I also like this idea. $ ln -s -v --relative usr/bin/foo usr/lib/foo/link-to-foo 'usr/lib/foo/link-to-foo' - 'foo' $

Re: ls -l: Avoid unnecessary getxattr() overhead

2012-02-26 Thread Pádraig Brady
On 02/26/2012 10:56 PM, Sven Breuner wrote: Pádraig Brady wrote on 02/20/2012 11:54 AM: On 02/20/2012 02:06 AM, Sven Breuner wrote: Pádraig Brady wrote on 02/20/2012 12:54 AM: I just booted RHEL 6.2 with selinux=0 on the kernel command line, so as I could test new files without a context

Re: [PATCH] doc: fix a wrong option reference in split invocation

2012-02-26 Thread Pádraig Brady
On 02/26/2012 02:12 PM, Jérémy Compostella wrote: All, I think there is a mistake in the output file names format description of the split invocation section. Indeed, there is a reference to a nonexistent option (-r). I think the right option is --number with r/n (round-robin distribution)

[PATCH] maint: refactor copy to use is_nul()

2012-03-01 Thread Pádraig Brady
* src/dd.c: Move is_nul() from here to ... * src/system.h: ... here * src/copy.c (sparse_copy): Adjust to use the refactored is_nul() --- src/copy.c | 33 +++-- src/dd.c | 21 - src/system.h | 21 + 3 files changed,

Re: split: support unlimited number of split files

2012-03-01 Thread Pádraig Brady
On 03/01/2012 07:44 PM, Jérémy Compostella wrote: Hi Pádraig, Finally, I found time to work again on this patch. I provided it as attachment. I'm not completely satisfied with the documentation part. I've tried to be more specific but it becomes quickly complicated. So I get back the

[PATCH] tests: work around a block alignment issue in dd/sparse

2012-03-02 Thread Pádraig Brady
Prompted by the continuous integration build failure at: http://hydra.nixos.org/build/2188210 (which uses XFS). * tests/dd/sparse (alloc_equal): Add a block allocation comparison function that accounts for variations due to alignment. --- tests/dd/sparse | 14 -- 1 files changed,

Re: split: support unlimited number of split files

2012-03-02 Thread Pádraig Brady
On 03/02/2012 04:27 PM, Jérémy Compostella wrote: [...] That's problematic. Is your locale ar_SA? as that's the only one on my system that triggers: My locale is fr_FR.utf8 for loc in $(locale -a | grep -vF .); do echo $loc; printf %s\n 2 1 . | LC_ALL=$loc sort done | grep 1 -B1 |

bug#10926: Minor problem with static building of coreutils-8.1[345]

2012-03-02 Thread Pádraig Brady
On 03/02/2012 09:35 AM, Heinz-Ado Arnolds wrote: Hi, I have a minor problem with the *static* building of coreutils. Building timeout requires libpthread in addition to librt. A simple patch is enclosed. Thanks a lot for your great work and kind regards, Is this on an older

Re: split: support unlimited number of split files

2012-03-02 Thread Pádraig Brady
On 03/02/2012 05:07 PM, Jérémy Compostella wrote: Ah drats, yes you need to check the combinations. $ printf %s\n .b a. | LC_ALL=en_US sort a. .b $ printf %s\n . a | LC_ALL=en_US sort . a Yep. BTW, do you know where I could find the sorting rules for each locale? I was looking for it to

Re: split: support unlimited number of split files

2012-03-02 Thread Pádraig Brady
On 03/02/2012 05:39 PM, Jérémy Compostella wrote: Pádraig, others, Do you know where I could find the sorting rules for each locale (for my personal interest)? They're part of glibc and installed on my Fedora system by default. /usr/share/i18n/locales/fr_FR

Re: basename BSD compatibility and filter mode

2012-03-03 Thread Pádraig Brady
On 03/03/2012 02:10 PM, Jérémy Compostella wrote: All, I'm interesting in implementing these features: 1. basename BSD options and behavior compatibility: Add the following options: -s, --suffix: specify the suffix -a, --multiple: every argument is treated as a string as if basename

Re: basename BSD compatibility and filter mode

2012-03-03 Thread Pádraig Brady
On 03/03/2012 07:58 PM, Jérémy Compostella wrote: On 03/03/2012 02:10 PM, Jérémy Compostella wrote: All, I'm interesting in implementing these features: 1. basename BSD options and behavior compatibility: Add the following options: -s, --suffix: specify the suffix -a, --multiple: every

Re: basename BSD compatibility and filter mode

2012-03-06 Thread Pádraig Brady
On 03/04/2012 07:09 PM, Jérémy Compostella wrote: [...] I just logged onto an OS X box there and you're right: $ printf %s\n 1/1 2/2 | xargs basename 1 $ printf %s\n 1/1 2/2 3/3| xargs basename 1 2 3 However I think it's dangerous to do that. If I was writing a script I would probably

Re: basename BSD compatibility and filter mode

2012-03-07 Thread Pádraig Brady
On 03/07/2012 02:02 AM, Pádraig Brady wrote: On 03/04/2012 07:09 PM, Jérémy Compostella wrote: [...] I just logged onto an OS X box there and you're right: $ printf %s\n 1/1 2/2 | xargs basename 1 $ printf %s\n 1/1 2/2 3/3| xargs basename 1 2 3 However I think it's dangerous to do

Re: [PATCH] doc: NEWS: correct bug introduced in ... version number

2012-03-09 Thread Pádraig Brady
On 03/09/2012 06:37 AM, Bernhard Voelker wrote: This fixes a typo in the NEWS of commit f7f398a du: fix -x: don't ignore non-directory arguments yesterday. Have a nice day, Berny From e3d303036345db49ace5fcd7216ac64c52bf024a Mon Sep 17 00:00:00 2001 From: Bernhard Voelker

Re: split: support unlimited number of split files

2012-03-10 Thread Pádraig Brady
On 03/10/2012 11:13 AM, Jérémy Compostella wrote: BTW, reviewing your changes I discovered that when a user specifies a suffix length zero the old behavior was to use the default length of 2 and the new is, of course, the suffix auto length way. Well spotted. I noticed that too, but thought 0

Re: [PATCH 4/6] realpath: let --relative-to default to --relative-base

2012-03-14 Thread Pádraig Brady
On 03/14/2012 08:38 PM, Eric Blake wrote: Most of the time, if someone wants to filter which paths are relative while leaving all others absolute, they also want to to the filtering based on the same --relative-to directory. Make this easier to specify. --- a/src/realpath.c +++

Re: [PATCH 0/6] realpath cleanups

2012-03-14 Thread Pádraig Brady
On 03/14/2012 08:38 PM, Eric Blake wrote: As promised, here's my cleaned up series for http://debbug.gnu.org/10472 This is very thorough. I can't find any logic issues at all. I'm not sure whether to squash 2 and 3 into one patch. separate is fine I'm not sure whether we want patch 6/6, so

Re: [PATCH 0/6] realpath cleanups

2012-03-14 Thread Pádraig Brady
On 03/14/2012 10:15 PM, Eric Blake wrote: On 03/14/2012 04:04 PM, Pádraig Brady wrote: On 03/14/2012 08:38 PM, Eric Blake wrote: As promised, here's my cleaned up series for http://debbug.gnu.org/10472 This is very thorough. I can't find any logic issues at all. I'm not sure whether

Re: new snapshot available: coreutils-8.15.74-be17e3

2012-03-16 Thread Pádraig Brady
I see the new sort-discrim test fails on systems without GMP (in this case solaris). The attached should fix it. cheers, Pádraig. From 020469e65861bac3d62a7d0bb197431bfb957647 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?P=C3=A1draig=20Brady?= p...@draigbrady.com Date: Fri, 16 Mar 2012 11:23:13 +

Re: new snapshot available: coreutils-8.15.74-be17e3

2012-03-16 Thread Pádraig Brady
After my patches mentioned previously in this thread, I get no failures on Fedora 15 2.6.40.4-5.fc15.x86_64 Mac OS X 10.6.8 Kernel 10.8.0: i386 Debian 5.0 2.6.26-2-sparc64-smp Solaris 10 SPARC-Enterprise-T5220 cheers, Pádraig.

Re: coreutils-8.15.74-be17e3 on Solaris

2012-03-19 Thread Pádraig Brady
On 03/17/2012 04:16 PM, Jim Meyering wrote: Bruno Haible wrote: On Solaris 9 and 10, there are 2 test failures: FAIL: misc/sort-discrim FAIL: dd/sparse These were not present in the previous test https://lists.gnu.org/archive/html/coreutils/2012-01/msg00049.html. Thanks. With the

Re: [PATCH] maint: fix typo in comment in stat.c

2012-03-19 Thread Pádraig Brady
On 03/19/2012 11:23 PM, Bernhard Voelker wrote: -/* Print the context information of FILENAME, and return true iff the +/* Print the context information of FILENAME, and return true if the I think that's more correct/descriptive as is. cheers, Pádraig.

Re: [PATCH] maint: ensure PATH_MAX is set correctly

2012-03-22 Thread Pádraig Brady
On 03/22/2012 10:53 AM, Eric Blake wrote: On 03/21/2012 10:53 PM, Pádraig Brady wrote: * src/system.h: Include gnulib's pathmax.h to ensure we set PATH_MAX only if needed. --- src/system.h |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/src/system.h b/src/system.h

Re: [PATCH v2] ln: add the --relative option

2012-03-22 Thread Pádraig Brady
Thanks for the review. I agree with all points, and split the patch as Eric suggested, and pushed. cheers, Pádraig.

Re: How to explicte specify -t be the non-blank to blank transition?

2012-03-29 Thread Pádraig Brady
On 03/28/2012 11:07 PM, Peng Yu wrote: Hi, I don't see a way to explicit set -t to non-blank to blank transition, although implicit it is set so. Is there a way to explictly set -t to non-blank to blank transition? No. More general, is there a way to set the separator to other

Re: [PATCH v2] ln: add the --relative option

2012-03-30 Thread Pádraig Brady
On 02/24/2012 01:04 PM, Eric Blake wrote: On 02/24/2012 04:11 AM, Pádraig Brady wrote: Why restrict this to symlinks - it could also be useful for hardlinks, right? Well hardlinks reference inodes and so are independent of any naming, whether relative or absolute etc. Furthermore, ln

Re: scp sparse dd file

2012-04-02 Thread Pádraig Brady
On 04/02/2012 10:30 PM, Simon Hintermann wrote: Hello all, I have a tricky one (so do I think)... My virtual machines are raw-based files, created with a dd if=/dev/zero of=.. bs=1M count=0 seek=12, for example. As I want to have native I/O performances on my servers, I do not use

Re: [PATCH] maint: replace a use of strcpy in chmod.c with memcpy

2012-04-16 Thread Pádraig Brady
On 04/16/2012 04:45 PM, Jim Meyering wrote: This is on the edge... I generally prefer to use memcpy when the length is already computed, so I propose to do that here. However, this is certainly not performance sensitive, and the strcpy invocation is slightly simpler and hence a little more

Re: crusade against strncpy/strcpy ;-)

2012-04-19 Thread Pádraig Brady
On 04/19/2012 12:15 PM, Jim Meyering wrote: strncpy is particularly bad, but even strcpy is best avoided. Yep, strncpy may not NUL terminate, so using it is awkward as detailed here: http://www.pixelbeat.org/programming/gcc/string_buffers.html stpcpy/stpncpy are appropriate here as the buffer

Re: [PATCH] maint: avoid reading lots of data from /dev/urandom

2012-04-24 Thread Pádraig Brady
On 04/24/2012 12:53 PM, Bernhard Voelker wrote: On 04/24/2012 01:15 PM, Pádraig Brady wrote: With those changes, the affected files are then very compressible. With some file system types/options, won't they occupy far fewer blocks than before? Good point. The dd/sparse one could

Re: Split command wait - Request

2012-04-26 Thread Pádraig Brady
On 04/26/2012 01:39 AM, Quinton Dunning wrote: To whom it may concern, Sometimes when I execute the split command I want to use removable media and take a file part over to another machine. To do this, the split command would have to have a switch that would pause and wait for a keystroke

Re: mkdir -pm bug?

2012-04-27 Thread Pádraig Brady
On 04/27/2012 12:52 PM, Henrikki Almusa wrote: Hi, I have a situation where I want to create with a script a directory path based on input. The mkdir -p allows this nicely. However since I want to enforce certain permissions on it I thought that I can use mkdir -pmmode to create this.

Re: Another rfe: cp this time

2012-04-27 Thread Pádraig Brady
On 04/27/2012 03:32 PM, Bruce Korb wrote: Our corporate infrastructure only allows CIFS shares. No FTP access. No scp access. Nope. Gotta be CIFS. One of these is on the other side of the pond. The pipe is fairly fat, but very, very long. Sometimes, like yesterday, after 8 hours of

Re: Another rfe: cp this time

2012-04-27 Thread Pádraig Brady
On 04/27/2012 06:47 PM, Pádraig Brady wrote: On 04/27/2012 06:15 PM, Bruce Korb wrote: Thank you for the suggestions. I did finish my particular task with rsync, but I'd still like something that finishes in less than 10 hours. Just to be clear, you started with cp, went home, resumed

Re: [PATCH] cat, cp, mv, install, split: Set the minimum IO block size used, to 64KiB

2012-04-30 Thread Pádraig Brady
On 04/30/2012 07:16 AM, Jim Meyering wrote: I think it's time to apply your patch: http://lists.gnu.org/archive/html/coreutils/2011-07/msg00059.html Here are numbers from a 3.2GHz i7-970 with 1333MHz DDR3: 1024=2.6 GB/s 2048=4.4 GB/s 4096=6.5 GB/s 8192=8.5 GB/s

Re: flock(1) exit code (enhancement request)

2012-04-30 Thread Pádraig Brady
On 04/30/2012 01:19 PM, Jan Kasprzak wrote: Hello, coreutils developers! I use flock(1) from coreutils in my scripts flock is from util-li...@vger.kernel.org cheers, Pádraig

Re: Another rfe: cp this time

2012-05-01 Thread Pádraig Brady
On 05/01/2012 05:15 AM, H. Peter Anvin wrote: On 04/27/2012 08:35 AM, Pádraig Brady wrote: Yes, cp is bad for high latency links as it has a 32KiB buffer which it serially reads to and writes from. Why this that, though? At least for file-to-file copy, it could certainly do much better

Re: Another rfe: cp this time

2012-05-01 Thread Pádraig Brady
On 05/01/2012 04:43 PM, Bruce Korb wrote: On Tue, May 1, 2012 at 1:17 AM, Pádraig Brady p...@draigbrady.com wrote: On 05/01/2012 05:15 AM, H. Peter Anvin wrote: On 04/27/2012 08:35 AM, Pádraig Brady wrote: 32KiB buffer which it serially reads to and writes from. Why this that, though

Re: [PATCH 3/3] maint: prohibit an operator at end of line

2012-05-02 Thread Pádraig Brady
On 05/02/2012 09:35 AM, Jim Meyering wrote: Eric Blake wrote: On 04/30/2012 08:25 AM, Eric Blake wrote: On 04/30/2012 07:08 AM, Jim Meyering wrote: Here's a new syntax-check rule (patch 3/3). 1 and 2 fix violations so that the new check passes. For now, this is only in coreutils (grep had

<    1   2   3   4   5   6   7   8   9   10   >