[PATCH 1/2] Add --verbose|-v to test-chmtime

DORMANTno replies

2 messages, 2 authors, 2016-06-15 · open the first message on its own page

[PATCH 1/2] Add --verbose|-v to test-chmtime

From: Alex Riesen <hidden>
Date: 2016-06-15 22:45:33

This allows us replace perl when getting the mtime of a file because
of time zone conversions, though at the moment only one platform which
does this has been identified: Cygwin when used with ActiveState Perl
(as usual).

The output format is:

    <mtime1> TAB <filename1> <LF>
    <mtime2> TAB <filename2> <LF>
    ...

which, if only mtime is needed can be parsed with cut(1):

    test-chmtime -v +0 filename1 | cut -f 1

Also, the change adds a description of programs features, with examples.

Signed-off-by: Alex Riesen <redacted>
---
 test-chmtime.c |   91 +++++++++++++++++++++++++++++++++++++++++++-------------
 1 files changed, 70 insertions(+), 21 deletions(-)

Re: [PATCH 1/2] Add --verbose|-v to test-chmtime

From: Jeff King <hidden>
Date: 2016-06-15 22:45:33

On Thu, Oct 30, 2008 at 12:26:24PM +0100, Alex Riesen wrote:
This allows us replace perl when getting the mtime of a file because
of time zone conversions, though at the moment only one platform which
does this has been identified: Cygwin when used with ActiveState Perl
(as usual).
[...]
    test-chmtime -v +0 filename1 | cut -f 1
Personally, I would have:

  - split the argument refactoring and the addition of the "-v" argument
    into two patches to make reviewers lives easier

  - just used a special timespec that means "don't change anything, but
    show show"

but I think those are mostly nitpicks, so I am OK with the series as-is.

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help