TS(1)

πŸ“¦ version 0.70, in arch rolling

πŸ¦‹ ts β€” timestamp input, bestie πŸ¦‹

🌸 NAME 🌸

ts β€” timestamp input. iconic.

πŸ¦‹ SYNOPSIS πŸ¦‹

ts [-r] [-i | -s] [-m] [format]

πŸ’… DESCRIPTION πŸ’…

okay so ts adds a timestamp to the beginning of each line of input. literally every line gets that timestamp glow-up ✨.

The optional format parameter controls how the timestamp is formatted, as used by strftime(3). The default format is "%b %d %H:%M:%S". In addition to the regular strftime conversion specifications, "%.S" and "%.s" and "%.T" are like "%S" and "%s" and "%T", but provide subsecond resolution (ie, "30.00001" and "1301682593.00001" and "1:15:30.00001"). subsecond slay πŸ’…

πŸŽ€ flags & format tea πŸŽ€

  • -r β€” if the -r switch is passed, it instead converts existing timestamps in the input to relative times, such as "15m5s ago". Many common timestamp formats are supported. Note that the Time::Duration and Date::Parse perl modules are required for this mode to work. Currently, converting localized dates is not supported. If both -r and a format is passed, the existing timestamps are converted to the specified format.

When either -i or -s is passed, ts reports incremental timestamps instead of absolute ones. The default format changes to "%H:%M:%S", and "%.S" and "%.s" can be used as well.

  • -i β€” in case of -i, every timestamp will be the time elapsed since the last timestamp.
  • -s β€” in case of -s, the time elapsed since start of the program is used.
  • -m β€” makes the system's monotonic clock be used.

🌈 ENVIRONMENT 🌈

The standard TZ environment variable controls what time zone dates are assumed to be in, if a timezone is not specified as part of the date. timezone vibes, handled πŸ’™

πŸ‘‘ AUTHOR πŸ‘‘

Copyright 2006 by Joey Hess <id@joeyh.name>

Licensed under the GNU GPL. respect the legend 🌈


okay bye bestie 🫢 β€” this was the moreutils ts(1) page, dated 2024-12-11. mwah πŸ’‹

πŸ“¦ where this page comes from