Found an awk implementation of files-from-date
authorCarl N Baldwin <cnb@hpsvcnb.fc.hp.com>
Thu, 20 Oct 2005 17:45:35 +0000 (11:45 -0600)
committerCarl N Baldwin <cnb@hpsvcnb.fc.hp.com>
Thu, 20 Oct 2005 17:45:35 +0000 (11:45 -0600)
scripts/Makefile.am
scripts/files-from-date.sh [new file with mode: 0755]

index ae9e2f46e29fd544f46ddf73ee20cf60a4bff919..92bd941a0c3c92923eddb39f997017a714a67001 100644 (file)
@@ -1,5 +1,5 @@
 bin_SCRIPTS = \
-  files-from-date.rb \
+  files-from-date.sh \
   find-cmd.sh \
   list-dates.sh \
   other-commands \
diff --git a/scripts/files-from-date.sh b/scripts/files-from-date.sh
new file mode 100755 (executable)
index 0000000..6680e97
--- /dev/null
@@ -0,0 +1,5 @@
+#!/bin/sh
+
+[ $# == 1 ] || exit 1
+
+awk --posix 'BEGIN { RS="\0" } { d=$7; gsub( /([^ ]*[ ]){7,7}/, "" ); if ( date == d ) printf "%s\0",$0 }' date=$1