Repository: whimsy Updated Branches: refs/heads/master c283f6795 -> 2075b050e
quick and dirty cross-check Project: https://git-dual.apache.org/repos/asf/whimsy/repo Commit: https://git-dual.apache.org/repos/asf/whimsy/commit/2075b050 Tree: https://git-dual.apache.org/repos/asf/whimsy/tree/2075b050 Diff: https://git-dual.apache.org/repos/asf/whimsy/diff/2075b050 Branch: refs/heads/master Commit: 2075b050ed8cfbd65fdbbc945b5a569f828af859 Parents: 5c728a6 Author: Sam Ruby <[email protected]> Authored: Mon Feb 22 12:02:53 2016 -0500 Committer: Sam Ruby <[email protected]> Committed: Mon Feb 22 12:03:36 2016 -0500 ---------------------------------------------------------------------- www/members/attendance-xcheck.cgi | 38 ++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) ---------------------------------------------------------------------- https://git-dual.apache.org/repos/asf/whimsy/blob/2075b050/www/members/attendance-xcheck.cgi ---------------------------------------------------------------------- diff --git a/www/members/attendance-xcheck.cgi b/www/members/attendance-xcheck.cgi new file mode 100755 index 0000000..1010801 --- /dev/null +++ b/www/members/attendance-xcheck.cgi @@ -0,0 +1,38 @@ +#!/usr/bin/ruby1.9.1 +$LOAD_PATH.unshift File.realpath(File.expand_path('../../../lib', __FILE__)) + +require 'whimsy/asf' +require 'json' + +# read in attendance +meetings = ASF::SVN['private/foundation/Meetings'] +json = JSON.parse(IO.read "#{meetings}/attendance.json") +attend = json['matrix'].keys + +# cross check against members.txt +missing = [] +ASF::Member.list.each do |id, info| + missing << info[:name] unless attend.delete info[:name] or info['status'] +end +missing.delete '' + +# produce HTML +_html do + _h1_ 'members.txt vs attendance.json cross-check' + + _h2_ 'Listed as attending a members meeting, but not in members.txt' + + _ul do + attend.sort.each do |name| + _li name + end + end + + _h2_ 'Listed in members.txt but not listed as attending a members meeting' + + _ul do + missing.sort.each do |name| + _li name + end + end +end
