You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by Sebastian Bazley <se...@apache.org> on 2016/01/23 13:53:00 UTC
[whimsy.git] [2/2] Commit 01b3dbd: Split non-committers into login/nologin groups
Commit 01b3dbdfb874764fd81319c65bcfeb71b73273d9:
Split non-committers into login/nologin groups
Branch: refs/heads/master
Author: Sebb <se...@apache.org>
Committer: Sebb <se...@apache.org>
Pusher: sebb <se...@apache.org>
------------------------------------------------------------
www/roster/public_ldap_committers.rb | +++++++++++++ --
------------------------------------------------------------
15 changes: 13 additions, 2 deletions.
------------------------------------------------------------
diff --git a/www/roster/public_ldap_committers.rb b/www/roster/public_ldap_committers.rb
index 9463b21..9b2db0b 100644
--- a/www/roster/public_ldap_committers.rb
+++ b/www/roster/public_ldap_committers.rb
@@ -11,7 +11,11 @@
# "uid": "Public Name",
# ...
# },
-# "non_committers": { // entries in 'ou=people,dc=apache,dc=org' who are not committers
+# "non_committers": { // entries in 'ou=people,dc=apache,dc=org' who are not committers but who can login
+# "uid": "Public Name",
+# ...
+# },
+# "non_committers_nologin": { // entries in 'ou=people,dc=apache,dc=org' who are not committers and have invalid shells
# "uid": "Public Name",
# ...
# }
@@ -32,6 +36,8 @@
ban = {}
# people entries that are not committers (and not in nologin)
non = {}
+# people entries that are not committers (in nologin)
+nonb = {}
peeps = ASF::Person.preload('loginShell',{}) # needed for the banned? method
@@ -46,7 +52,11 @@
peeps.sort_by {|a| a.name}.each do |e|
if ASF.committers.include? e
else
- non[e.name] = e.public_name
+ if e.banned?
+ nonb[e.name] = e.public_name
+ else
+ non[e.name] = e.public_name
+ end
end
end
@@ -56,6 +66,7 @@
committers: ids,
committers_nologin: ban,
non_committers: non,
+ non_committers_nologin: nonb,
}
# format as JSON