Bug 102609 - [patch] Add filtering capability to date(1)
Summary: [patch] Add filtering capability to date(1)
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: 6.1-STABLE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
Depends on:
Reported: 2006-08-28 16:40 UTC by Oliver Fromme
Modified: 2018-01-03 05:12 UTC (History)
1 user (show)

See Also:

file.diff (3.67 KB, patch)
2006-08-28 16:40 UTC, Oliver Fromme
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Oliver Fromme 2006-08-28 16:40:18 UTC
Julian Elischer started a thread in the -current mailing list,
proposing an addition to date(1) that turns it into a filter,
reading lines from stdin, adding a time stamp, and writing it
to stdout.  This is Julian's mail that started the thread:


This PR contains a somewhat different approach to the problem.
It has the same capability as Julian's patch, but it doesn't
require a new command line option letter.  It also provides
better control over the placement of the time stamps, and it
handles arbitrarily long lines.  A description can be found


Basically, it implements a new conversion specification "%*"
(it can be escaped with a double percent "%%*" sign as usual).
If it occurs in the format string, filter mode is enabled:
A loop is entered, reading lines from stdin and writing to
stdout.  For each line, the format string is expanded as
usual, and the line read from stdin is inserted in the place
of the "%*" character seqeuence.  The result is written to

Comment 1 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 07:59:10 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped