You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@whimsical.apache.org by ru...@apache.org on 2016/08/04 17:25:17 UTC

[whimsy] branch master updated (ffe71f3 -> 396f735)

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

rubys pushed a change to branch master
in repository https://git-dual.apache.org/repos/asf/whimsy.git.

      from  ffe71f3   temporarily disable submit button
       new  95aa14f   allow the number of ICLAs to be scanned to vary
       new  396f735   cleanup

The 2 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "adds" were already present in the repository and have only
been added to this reference.


Summary of changes:
 www/officers/acreq.cgi | 21 +++++++++++----------
 1 file changed, 11 insertions(+), 10 deletions(-)

-- 
To stop receiving notification emails like this one, please contact
['"commits@whimsical.apache.org" <co...@whimsical.apache.org>'].

[whimsy] 01/02: allow the number of ICLAs to be scanned to vary

Posted by ru...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/whimsy.git

commit 95aa14fc54216112cd38e4b10cce88accd3211c9
Author: Sam Ruby <ru...@intertwingly.net>
AuthorDate: Thu Aug 4 13:24:32 2016 -0400

    allow the number of ICLAs to be scanned to vary
---
 www/officers/acreq.cgi | 15 ++++++++++-----
 1 file changed, 10 insertions(+), 5 deletions(-)

diff --git a/www/officers/acreq.cgi b/www/officers/acreq.cgi
index a6611e6..9b9e02a 100755
--- a/www/officers/acreq.cgi
+++ b/www/officers/acreq.cgi
@@ -57,13 +57,18 @@ podlings = ASF::Podling.list.select {|podling| podling.status == 'current'}.
   map(&:name).sort
 
 # grab the list of iclas that have no ids assigned
-query_string = CGI::parse ENV['QUERY_STRING']
-if query_string.has_key? 'fulllist'
+query = CGI::parse ENV['QUERY_STRING']
+iclas = Array(query['iclas']).last
+email = Array(query['email']).last
+if iclas == 'all'
   iclas = Hash[*officers.scan(/^notinavail:.*?:(.*?):(.*?):Signed CLA/).
     flatten.reverse]
+elsif iclas == '1' and email and officers =~ /^notinavail:.*?:(.*?):#{email}:/
+  iclas = {email => $1}
 else
+  count = iclas ? iclas.to_i : 300 rescue 300
   oldrev = \
-    `#{SVN} log --incremental -q -r HEAD:0 -l300 -- #{OFFICERS}/iclas.txt`.
+    `#{SVN} log --incremental -q -r HEAD:0 -l#{count} -- #{OFFICERS}/iclas.txt`.
     split("\n")[-1].split()[0][1..-1].to_i
   iclas = Hash[*`#{SVN} diff -r #{oldrev}:HEAD -- #{OFFICERS}/iclas.txt`.
     scan(/^[+]notinavail:.*?:(.*?):(.*?):Signed CLA/).flatten.reverse]
@@ -349,13 +354,13 @@ _html do
 
     unless _.post?
       _p do
-        if @fulllist
+        if @iclas == 'all'
           _span 'This page shows all ICLAs ever received.  Click here to'
           _a 'show only ICLAs received recently', href: '?'
           _span '.'
         else
           _span 'This page shows only ICLAs received recently.  Click here to'
-          _a 'choose from the full list of ICLA submitters', href: '?fulllist=1'
+          _a 'choose from the full list of ICLA submitters', href: '?iclas=all'
           _span '.'
         end
       end

-- 
To stop receiving notification emails like this one, please contact
"commits@whimsical.apache.org" <co...@whimsical.apache.org>.

[whimsy] 02/02: cleanup

Posted by ru...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

rubys pushed a commit to branch master
in repository https://git-dual.apache.org/repos/asf/whimsy.git

commit 396f735373d36fdab9845ec2c9c45ff6eb94fb46
Author: Sam Ruby <ru...@intertwingly.net>
AuthorDate: Thu Aug 4 13:25:01 2016 -0400

    cleanup
---
 www/officers/acreq.cgi | 6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff --git a/www/officers/acreq.cgi b/www/officers/acreq.cgi
index 9b9e02a..98d0809 100755
--- a/www/officers/acreq.cgi
+++ b/www/officers/acreq.cgi
@@ -287,10 +287,6 @@ _html do
           cc      cc_list
           subject "[FORM] Account Request - #{requestor}: #{@name}"
 
-          ENV['REMOTE_ADDR'] =~ /(\w[\w.-]+)/
-          ra = $1
-          ra.untaint
-
           body <<-EOF.gsub(/^ {12}/, '').gsub(/(Vote reference:)?\n\s+\n/, "\n\n")
             Prospective userid: #{@user}
             Full name: #{@name}
@@ -303,7 +299,7 @@ _html do
 
             -- 
             Submitted by https://#{ENV['HTTP_HOST']}#{ENV['REQUEST_URI'].split('?').first}
-            From #{`/usr/bin/host #{ra}`.chomp}
+            From #{`/usr/bin/host #{ENV['REMOTE_ADDR'].dup.untaint}`.chomp}
             Using #{ENV['HTTP_USER_AGENT']}
           EOF
         end

-- 
To stop receiving notification emails like this one, please contact
"commits@whimsical.apache.org" <co...@whimsical.apache.org>.