[BACK]Return to ts.1 CVS log [TXT][DIR] Up to [local] / src / usr.bin / ts

Annotation of src/usr.bin/ts/ts.1, Revision 1.1

1.1     ! job         1: .\"    $OpenBSD$
        !             2: .\"
        !             3: .\" Copyright (c) 2022 Job Snijders <job@openbsd.org>
        !             4: .\"
        !             5: .\" Permission to use, copy, modify, and distribute this software for any
        !             6: .\" purpose with or without fee is hereby granted, provided that the above
        !             7: .\" copyright notice and this permission notice appear in all copies.
        !             8: .\"
        !             9: .\" THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
        !            10: .\" WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
        !            11: .\" MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
        !            12: .\" ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
        !            13: .\" WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
        !            14: .\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
        !            15: .\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
        !            16: .\"
        !            17: .Dd $Mdocdate: June 28 2022 $
        !            18: .Dt TS 1
        !            19: .Os
        !            20: .Sh NAME
        !            21: .Nm ts
        !            22: .Nd timestamp input
        !            23: .Sh SYNOPSIS
        !            24: .Nm ts
        !            25: .Op Fl i | s
        !            26: .Op Ar format
        !            27: .Sh DESCRIPTION
        !            28: When invoked, the
        !            29: .Nm
        !            30: utility adds a timestamp to the beginning of each line of input.
        !            31: .Pp
        !            32: The options are as follows:
        !            33: .Bl -tag -width Ds
        !            34: .It Fl i
        !            35: Display time elapsed since the last timestamp.
        !            36: .It Fl s
        !            37: Display time elapsed since the start of the program.
        !            38: .El
        !            39: .Pp
        !            40: The optional
        !            41: .Ar format
        !            42: argument controls how the timestamp is displayed, according to the conversion
        !            43: specifications described in the
        !            44: .Xr strftime 3
        !            45: manual page.
        !            46: The default format is
        !            47: .Qq %b %d %H:%M:%S ,
        !            48: or
        !            49: .Qq %H:%M:%S
        !            50: if an option is used.
        !            51: .Pp
        !            52: The following non-standard conversion specifications append microsecond
        !            53: resolution:
        !            54: .Cm \&%.S ,
        !            55: .Cm \&%.s ,
        !            56: and
        !            57: .Cm \&%.T ;
        !            58: which are similar to
        !            59: .Cm \&%S ,
        !            60: .Cm \&%s ,
        !            61: and
        !            62: .Cm \&%T .
        !            63: Examples:
        !            64: .Qq 10.00001 ,
        !            65: .Qq 1656427781.00001 ,
        !            66: and
        !            67: .Qq 4:20:00.00001 .
        !            68: .Sh EXAMPLES
        !            69: .Bd -literal -offset indent
        !            70: $ (echo foo; sleep 2; echo bar) | ts
        !            71: Jun 28 12:13:38 foo
        !            72: Jun 28 12:13:40 bar
        !            73:
        !            74: $ ls | ts -i %.S
        !            75: 00.000452 CVS
        !            76: 00.000595 Makefile
        !            77: 00.000004 ts.1
        !            78: 00.000004 ts.c
        !            79: .Ed
        !            80: .Sh HISTORY
        !            81: A
        !            82: .Nm
        !            83: utility first appeared in the moreutils collection by Joey Hess, and was
        !            84: rewritten from scratch for
        !            85: .Ox 7.2 .
        !            86: .Sh AUTHORS
        !            87: This
        !            88: .Nm
        !            89: utility was written by
        !            90: .An Job Snijders Aq Mt job@openbsd.org
        !            91: and
        !            92: .An Claudio Jeker Aq Mt claudio@openbsd.org .