You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by se...@apache.org on 2018/05/02 19:10:06 UTC

[whimsy] branch master updated: Don't include Officers in non-PMC or committees

This is an automated email from the ASF dual-hosted git repository.

sebb pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/whimsy.git


The following commit(s) were added to refs/heads/master by this push:
     new a7ef7d1  Don't include Officers in non-PMC or committees
a7ef7d1 is described below

commit a7ef7d17a4d3f43aeebb52505e2a011b9d4ff46a
Author: Sebb <se...@apache.org>
AuthorDate: Wed May 2 20:10:04 2018 +0100

    Don't include Officers in non-PMC or committees
---
 lib/whimsy/asf/committee.rb | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)

diff --git a/lib/whimsy/asf/committee.rb b/lib/whimsy/asf/committee.rb
index 6346b5d..bb5021c 100644
--- a/lib/whimsy/asf/committee.rb
+++ b/lib/whimsy/asf/committee.rb
@@ -360,16 +360,16 @@ module ASF
         end
 
       # Extract the non-PMC committees (e-mail address may be absent)
-      # first drop leading text so we only match non-PMCs
-      @nonpmcs = head.sub(/.*?also has /m,'').
+      # first drop leading text (and Officers) so we only match non-PMCs
+      @nonpmcs = head.sub(/.*?also has /m,'').sub(/ Officers:.*/m,'').
         scan(/^[ \t]+(\w.*?)(?:[ \t][ \t]|[ \t]?$)/).flatten.uniq.
         map {|name| list[name]}
 
       # Extract officers
-      # first drop leading text so we only match officers
-      @officers = head.sub(/.*?also has .* Officers/m,'').
-        scan(/^[ \t]+(\w.*?)(?:[ \t][ \t]|[ \t]?$)/).flatten.uniq.
-        map {|name| list[name]}
+      # first drop leading text so we only match officers at end of section
+      @officers = head.sub(/.*?also has .*? Officers/m,'').
+        scan(/^[ \t]+(\w.*?)(?:[ \t][ \t]|[ \t]?$)/).flatten.
+        map {|name| puts name; list[name]}
 
       # for each committee in section 3
       info.each do |roster|
@@ -418,15 +418,14 @@ module ASF
           end
         end
       end
-
-      @committee_info = list.values.uniq
+      @committee_info = (list.values - @officers).uniq
     end
 
     # return a list of PMC committees.  Data is obtained from
     # <tt>committee-info.txt</tt>
     def self.pmcs
       committees = ASF::Committee.load_committee_info
-      committees - @nonpmcs
+      committees - @nonpmcs - @officers
     end
 
     # return a list of non-PMC committees.  Data is obtained from

-- 
To stop receiving notification emails like this one, please contact
sebb@apache.org.