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 ecba200  INFRA-22491 - auth.conf replaced by svnauthz.yaml
ecba200 is described below

commit ecba2005d7ff2fb2c4858fa1dc7cf7b84c05acc7
Author: Sebb <[email protected]>
AuthorDate: Fri Dec 10 00:29:24 2021 +0000

    INFRA-22491 - auth.conf replaced by svnauthz.yaml
---
 lib/whimsy/asf/auth.rb | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/lib/whimsy/asf/auth.rb b/lib/whimsy/asf/auth.rb
index 23b394a..1c3666d 100644
--- a/lib/whimsy/asf/auth.rb
+++ b/lib/whimsy/asf/auth.rb
@@ -35,8 +35,8 @@ module ASF
       # extract the xxx={auth} names
       groups = read_auth.scan(/^([-\w]+)=\{auth\}/).flatten
       # extract the group = list details and return the appropriate ones
-      read_conf.scan(/^([-\w]+) *= *(\w.*)?$/).each do |pmc, ids|
-        yield pmc, (ids || '').split(' ') if groups.include? pmc
+      read_conf.each do |pmc, ids|
+        yield pmc, ids if groups.include? pmc
       end
     end
 
@@ -49,7 +49,7 @@ module ASF
 
     # read the config file - extract the [explicit] section
     def read_conf
-      File.read(File.join(@auth, 
'auth.conf')).scan(/^\[explicit\].*(?:^\[)?/m).first rescue ''
+      YAML.safe_load(File.read(File.join(@auth, 'svnauthz.yaml')))['explicit']
     end
 
     # read the auth template; extract [groups]

Reply via email to