On Sat, 18 Feb 2017 03:28:03 +0000 Colin Watson <cjwat...@debian.org> wrote:
> This version is much shorter and easier to understand than the > shell/awk version: we don't have to worry about convincing ls to > produce output that we can parse, and we don't have to play games > with the way that the same field may contain either the year or the > time depending on how old the file is. Attached please find fdate.c. It accepts filename argments and prints the files' mtimes (and, optionally, names). Like date(1), it accepts a strftime format argument, defaulting to yyyy-mm-dd. If you would like to use it instead, i can provide the necessary GNU paperwork. $ fdate ~/projects/3/groff/* 2016-04-21 2013-11-12 2016-04-19 $ fdate -v +'%d %B %Y' ~/projects/3/groff/* 21 April 2016 /home/jklowden/projects/3/groff/groff 12 November 2013 /home/jklowden/projects/3/groff/mkgrft 19 April 2016 /home/jklowden/projects/3/groff/sidebar --jkl
fdate.c
Description: Binary data