You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@whimsical.apache.org by Craig L Russell <cr...@oracle.com> on 2015/11/15 20:53:33 UTC

Tooling for icla-lint

I’d like to implement some tooling for the icla-lint page.

What I’d like to do is to add buttons on each line:
(send email) this would send an email to the address in the iclas.txt entry requesting a new icla

(remove entry) this would remove the entry in iclas.txt and send an email

The idea is to contact folks with an iclas.txt entry whose icla cannot be found. 

Is the library set up to facilitate this kind of stuff?

Where should I look for how to implement this?

Thanks,

Craig

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Tue, Nov 17, 2015 at 9:00 PM, Craig L Russell
<cr...@oracle.com> wrote:
> Here’s my latest attempt. A couple of questions.
>
> 1. When I create the button, I set data_email to the email address.
>
> But when I add the event listener, I getAttribute on data-email. Is there some magic that transforms data_email to data-email?

Yup.  :-)

Back story: HTML attributes (and element names) may have dashes in
them, and rarely (if ever) have underscores in them.  Variable names
in Ruby can't have dashes in them, but can have underscores.  So when
I generate the HTML (view source on the page to see what is
generated), I convert underscores to dashes.  This implementation
detail "bleeds through" when you call an underlying DOM function like
getAttribute.

> 2. I’m missing the lesson on creating new line characters in strings. \n doesn’t seem to work.

Switch from single quotes to double quotes.
https://en.wikibooks.org/wiki/Ruby_Programming/Strings

> 3. How do I tell email to use my clr at apache.org address?

When you push the button, it launches your email client.  Your email
client knows who you are, and may even allow you to change between
multiple addresses.  It also will allow you to edit the subject and/or
body before sending, or even chose to cancel sending entirely.

> Thanks,
>
> Craig

The diff below looks good, but longer term you might want to add if
statements to vary the subject and/or body based on the type of issue?

- Sam Ruby


> clr% svn diff
> Index: icla-lint.cgi
> ===================================================================
> --- icla-lint.cgi       (revision 972670)
> +++ icla-lint.cgi       (working copy)
> @@ -122,7 +122,8 @@
>            end
>
>            _td do
> -            _button 'email', data_id: id
> +            _button 'email', data_email: "#{name} <#{email}>",
> +              data_issue: note, data_name: name
>              _span note
>            end
>
> @@ -151,8 +152,24 @@
>      buttons = document.querySelectorAll('button')
>      for i in 0...buttons.length
>        buttons[i].addEventListener('click') do |event|
> -        id = event.target.getAttribute('data-id')
> -        alert(id)
> +        email = event.target.getAttribute('data-email')
> +        issue = event.target.getAttribute('data-issue')
> +        name  = event.target.getAttribute('data-name')
> +
> +        destination = "mailto:#{email}?cc=secretary@apache.org"
> +        subject = 'Your Apache ICLA'
> +        from = 'clr@apache.org'
> +        body = 'Dear ' + name + '\n' +
> +            'While reviewing our records, we have not been able to locate your ICLA.\n' +
> +            'Can you please resubmit to secretary@apache.org? http://apache.org/licenses/#submitting\n' +
> +            'Best regards,\n\n' +
> +            'Craig'
> +
> +        window.location = destination +
> +          "&from=#{encodeURIComponent(from)}" +
> +          "&subject=#{encodeURIComponent(subject)}" +
> +          "&body=#{encodeURIComponent(body)}"
> +
>        end
>      end
>
>> On Nov 16, 2015, at 10:24 PM, Sam Ruby <ru...@intertwingly.net> wrote:
>>
>> On Tue, Nov 17, 2015 at 12:31 AM, Craig L Russell
>> <cr...@oracle.com> wrote:
>>> Another thought on this, since it would be nice to have this feature work both on a client and on the whimsy service.
>>>
>>> Maybe the “alert” could create an email message that can be edited to suit (similar to the commit message in SA tool) and once it’s perfect, the (send) button would send the completed, edited message to the email system to be sent.
>>>
>>> I’ll experiment with the alert dialog box to see what is involved.
>>
>> I do suggest that you try the following patch before you explore a dialog box:
>>
>> Index: icla-lint.cgi
>> ===================================================================
>> --- icla-lint.cgi    (revision 972667)
>> +++ icla-lint.cgi    (working copy)
>> @@ -122,7 +122,8 @@
>>           end
>>
>>           _td do
>> -            _button 'email', data_id: id
>> +            _button 'email', data_email: "#{name} <#{email}>",
>> +              data_issue: note
>>             _span note
>>           end
>>
>> @@ -151,8 +152,16 @@
>>     buttons = document.querySelectorAll('button')
>>     for i in 0...buttons.length
>>       buttons[i].addEventListener('click') do |event|
>> -        id = event.target.getAttribute('data-id')
>> -        alert(id)
>> +        email = event.target.getAttribute('data-email')
>> +        issue = event.target.getAttribute('data-issue')
>> +
>> +        destination = "mailto:#{email}?cc=secretary@apache.org"
>> +        subject = issue
>> +        body = 'blah, blah, blah'
>> +
>> +        window.location = destination +
>> +          "&subject=#{encodeURIComponent(subject)}" +
>> +          "&body=#{encodeURIComponent(body)}"
>>       end
>>     end
>>
>> ===================================================================
>>
>> If you want to go the dialog box route, what the board agenda tool
>> uses is Bootstrap modals:
>>
>> http://getbootstrap.com/javascript/#modals
>>
>> To pull in bootstrap, add the following to the top of your script:
>>
>> require 'wunderbar/bootstrap/theme'
>>
>> Have fun!
>>
>> - Sam Ruby
>
> Craig L Russell
> Architect, Oracle
> http://db.apache.org/jdo
> 408 276-5638 mailto:Craig.Russell@oracle.com
> P.S. A good JDO? O, Gasp!
>

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
Here’s my latest attempt. A couple of questions.

1. When I create the button, I set data_email to the email address.

But when I add the event listener, I getAttribute on data-email. Is there some magic that transforms data_email to data-email?

2. I’m missing the lesson on creating new line characters in strings. \n doesn’t seem to work.

3. How do I tell email to use my clr at apache.org address? 

Thanks,

Craig

clr% svn diff
Index: icla-lint.cgi
===================================================================
--- icla-lint.cgi	(revision 972670)
+++ icla-lint.cgi	(working copy)
@@ -122,7 +122,8 @@
           end
 
           _td do
-            _button 'email', data_id: id
+            _button 'email', data_email: "#{name} <#{email}>",
+              data_issue: note, data_name: name
             _span note
           end
 
@@ -151,8 +152,24 @@
     buttons = document.querySelectorAll('button')
     for i in 0...buttons.length
       buttons[i].addEventListener('click') do |event|
-        id = event.target.getAttribute('data-id')
-        alert(id)
+        email = event.target.getAttribute('data-email')
+        issue = event.target.getAttribute('data-issue')
+        name  = event.target.getAttribute('data-name')
+
+        destination = "mailto:#{email}?cc=secretary@apache.org"
+        subject = 'Your Apache ICLA'
+        from = 'clr@apache.org'
+        body = 'Dear ' + name + '\n' +
+            'While reviewing our records, we have not been able to locate your ICLA.\n' +
+            'Can you please resubmit to secretary@apache.org? http://apache.org/licenses/#submitting\n' +
+            'Best regards,\n\n' +
+            'Craig'
+
+        window.location = destination +
+          "&from=#{encodeURIComponent(from)}" +
+          "&subject=#{encodeURIComponent(subject)}" +
+          "&body=#{encodeURIComponent(body)}"
+
       end
     end

> On Nov 16, 2015, at 10:24 PM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> On Tue, Nov 17, 2015 at 12:31 AM, Craig L Russell
> <cr...@oracle.com> wrote:
>> Another thought on this, since it would be nice to have this feature work both on a client and on the whimsy service.
>> 
>> Maybe the “alert” could create an email message that can be edited to suit (similar to the commit message in SA tool) and once it’s perfect, the (send) button would send the completed, edited message to the email system to be sent.
>> 
>> I’ll experiment with the alert dialog box to see what is involved.
> 
> I do suggest that you try the following patch before you explore a dialog box:
> 
> Index: icla-lint.cgi
> ===================================================================
> --- icla-lint.cgi    (revision 972667)
> +++ icla-lint.cgi    (working copy)
> @@ -122,7 +122,8 @@
>           end
> 
>           _td do
> -            _button 'email', data_id: id
> +            _button 'email', data_email: "#{name} <#{email}>",
> +              data_issue: note
>             _span note
>           end
> 
> @@ -151,8 +152,16 @@
>     buttons = document.querySelectorAll('button')
>     for i in 0...buttons.length
>       buttons[i].addEventListener('click') do |event|
> -        id = event.target.getAttribute('data-id')
> -        alert(id)
> +        email = event.target.getAttribute('data-email')
> +        issue = event.target.getAttribute('data-issue')
> +
> +        destination = "mailto:#{email}?cc=secretary@apache.org"
> +        subject = issue
> +        body = 'blah, blah, blah'
> +
> +        window.location = destination +
> +          "&subject=#{encodeURIComponent(subject)}" +
> +          "&body=#{encodeURIComponent(body)}"
>       end
>     end
> 
> ===================================================================
> 
> If you want to go the dialog box route, what the board agenda tool
> uses is Bootstrap modals:
> 
> http://getbootstrap.com/javascript/#modals
> 
> To pull in bootstrap, add the following to the top of your script:
> 
> require 'wunderbar/bootstrap/theme'
> 
> Have fun!
> 
> - Sam Ruby

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Tue, Nov 17, 2015 at 12:31 AM, Craig L Russell
<cr...@oracle.com> wrote:
> Another thought on this, since it would be nice to have this feature work both on a client and on the whimsy service.
>
> Maybe the “alert” could create an email message that can be edited to suit (similar to the commit message in SA tool) and once it’s perfect, the (send) button would send the completed, edited message to the email system to be sent.
>
> I’ll experiment with the alert dialog box to see what is involved.

I do suggest that you try the following patch before you explore a dialog box:

Index: icla-lint.cgi
===================================================================
--- icla-lint.cgi    (revision 972667)
+++ icla-lint.cgi    (working copy)
@@ -122,7 +122,8 @@
           end

           _td do
-            _button 'email', data_id: id
+            _button 'email', data_email: "#{name} <#{email}>",
+              data_issue: note
             _span note
           end

@@ -151,8 +152,16 @@
     buttons = document.querySelectorAll('button')
     for i in 0...buttons.length
       buttons[i].addEventListener('click') do |event|
-        id = event.target.getAttribute('data-id')
-        alert(id)
+        email = event.target.getAttribute('data-email')
+        issue = event.target.getAttribute('data-issue')
+
+        destination = "mailto:#{email}?cc=secretary@apache.org"
+        subject = issue
+        body = 'blah, blah, blah'
+
+        window.location = destination +
+          "&subject=#{encodeURIComponent(subject)}" +
+          "&body=#{encodeURIComponent(body)}"
       end
     end

===================================================================

If you want to go the dialog box route, what the board agenda tool
uses is Bootstrap modals:

http://getbootstrap.com/javascript/#modals

To pull in bootstrap, add the following to the top of your script:

require 'wunderbar/bootstrap/theme'

Have fun!

- Sam Ruby

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
Another thought on this, since it would be nice to have this feature work both on a client and on the whimsy service.

Maybe the “alert” could create an email message that can be edited to suit (similar to the commit message in SA tool) and once it’s perfect, the (send) button would send the completed, edited message to the email system to be sent.

I’ll experiment with the alert dialog box to see what is involved.

Craig

> On Nov 16, 2015, at 5:44 PM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> On Mon, Nov 16, 2015 at 8:39 PM, Craig L Russell
> <cr...@oracle.com> wrote:
>> I’ve added a button in the issue column.
>> 
>> I think I’ll keep the email column. It’s useful.
>> 
>> Next I need to think about what the (email) button needs to do. Definitely not send email, at least not yet. Rather, it should construct a message and call the email client with the proposed contents of the email. So for now, this isn’t really a remote operation. It would need to run on a machine with an email client.
>> 
>> My idea is that with the email open in the client, I could add some information and then send the message.
> 
> That's exactly what "launch_email_client" in the following code does:
> 
> https://github.com/rubys/whimsy-agenda/blob/master/views/buttons/email.js.rb
> 
> Change the values of destination, subject, and body.  Copy the
> window.location line verbatim.  You don't need a separate method
> (def...end), simply inline this code.
> 
> A few messages back, I showed how to add an event listener to buttons.
> 
>> The email will be different for different types of issues.
> 
> "if" statements are your friend. :-)
> 
>> Craig
> 
> - Sam Ruby

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Mon, Nov 16, 2015 at 8:39 PM, Craig L Russell
<cr...@oracle.com> wrote:
> I’ve added a button in the issue column.
>
> I think I’ll keep the email column. It’s useful.
>
> Next I need to think about what the (email) button needs to do. Definitely not send email, at least not yet. Rather, it should construct a message and call the email client with the proposed contents of the email. So for now, this isn’t really a remote operation. It would need to run on a machine with an email client.
>
> My idea is that with the email open in the client, I could add some information and then send the message.

That's exactly what "launch_email_client" in the following code does:

https://github.com/rubys/whimsy-agenda/blob/master/views/buttons/email.js.rb

Change the values of destination, subject, and body.  Copy the
window.location line verbatim.  You don't need a separate method
(def...end), simply inline this code.

A few messages back, I showed how to add an event listener to buttons.

> The email will be different for different types of issues.

"if" statements are your friend. :-)

> Craig

- Sam Ruby

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
I’ve added a button in the issue column.

I think I’ll keep the email column. It’s useful.

Next I need to think about what the (email) button needs to do. Definitely not send email, at least not yet. Rather, it should construct a message and call the email client with the proposed contents of the email. So for now, this isn’t really a remote operation. It would need to run on a machine with an email client.

My idea is that with the email open in the client, I could add some information and then send the message.

The email will be different for different types of issues. 

Craig

> On Nov 16, 2015, at 10:51 AM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> On Mon, Nov 16, 2015 at 12:55 PM, Craig L Russell
> <cr...@oracle.com> wrote:
>> 
>> I’ll take a look now at adding buttons.
> 
> Cool.  The document.scan line is not currently extracting the email
> address.  You will need this.  I find it is easiest to make that
> change, verify that it works, before moving on.  Adding a line
> containing "_td email" in the table will show the email address.  Once
> it is working, you can remove the line.
> 
> For sending email, you might want to look at "launch_email_client" in
> the following code:
> 
> https://github.com/rubys/whimsy-agenda/blob/master/views/buttons/email.js.rb
> 
> - Sam Ruby

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Mon, Nov 16, 2015 at 12:55 PM, Craig L Russell
<cr...@oracle.com> wrote:
>
> I’ll take a look now at adding buttons.

Cool.  The document.scan line is not currently extracting the email
address.  You will need this.  I find it is easiest to make that
change, verify that it works, before moving on.  Adding a line
containing "_td email" in the table will show the email address.  Once
it is working, you can remove the line.

For sending email, you might want to look at "launch_email_client" in
the following code:

https://github.com/rubys/whimsy-agenda/blob/master/views/buttons/email.js.rb

- Sam Ruby

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
> On Nov 16, 2015, at 9:40 AM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> On Mon, Nov 16, 2015 at 11:24 AM, Craig L Russell
> <cr...@oracle.com> wrote:
>> 
>>> On Nov 16, 2015, at 12:19 AM, Sam Ruby <ru...@intertwingly.net> wrote:
>>> 
>>> ruby2js
>> 
>> Progress.
>> 
>> So I tried ruby icla-lint.cgi —port=8080
>> 
>> and a web page http://localhost:8080
>> 
>> Internal Server Error
>> 
>> #<NoMethodError: undefined method `+' for nil:NilClass>
>>  icla-lint.cgi:56:in `block in <main>'
> 
> Can you verify that at least one entry in the :svn: portion of your
> ~/.whimsy file names a directory containing a svn checkout of either
> https://svn.apache.org/repos/private/documents or
> https://svn.apache.org/repos/private/documents/iclas?
> 
cat .whimsy
---
     :svn:
     - /Users/clr/apache/foundation
     - /Users/clr/apache/foundation

[CraigRussell:~] clr% svn info /Users/clr/apache/foundation
Path: apache/foundation
Working Copy Root Path: /Users/clr/apache/foundation
URL: https://svn.apache.org/repos/private/foundation
Relative URL: ^/foundation
Repository Root: https://svn.apache.org/repos/private
Repository UUID: 694d45b4-53eb-0310-9336-ddcd440d954d
Revision: 63364
Node Kind: directory
Schedule: normal
Last Changed Author: cdouglas
Last Changed Rev: 63363
Last Changed Date: 2015-11-15 18:34:15 -0800 (Sun, 15 Nov 2015)

When I changed the second foundation to documents, the error went away and the web page loaded.

I’ll take a look now at adding buttons.

Thanks,

Craig

>> Craig L Russell
>> Architect, Oracle
>> http://db.apache.org/jdo
>> 408 276-5638 mailto:Craig.Russell@oracle.com
>> P.S. A good JDO? O, Gasp!
> 
> - Sam Ruby

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Mon, Nov 16, 2015 at 11:24 AM, Craig L Russell
<cr...@oracle.com> wrote:
>
>> On Nov 16, 2015, at 12:19 AM, Sam Ruby <ru...@intertwingly.net> wrote:
>>
>> ruby2js
>
> Progress.
>
> So I tried ruby icla-lint.cgi —port=8080
>
> and a web page http://localhost:8080
>
> Internal Server Error
>
> #<NoMethodError: undefined method `+' for nil:NilClass>
>   icla-lint.cgi:56:in `block in <main>'

Can you verify that at least one entry in the :svn: portion of your
~/.whimsy file names a directory containing a svn checkout of either
https://svn.apache.org/repos/private/documents or
https://svn.apache.org/repos/private/documents/iclas?

> Craig L Russell
> Architect, Oracle
> http://db.apache.org/jdo
> 408 276-5638 mailto:Craig.Russell@oracle.com
> P.S. A good JDO? O, Gasp!

- Sam Ruby

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
> On Nov 16, 2015, at 12:19 AM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> ruby2js

Progress.

So I tried ruby icla-lint.cgi —port=8080

and a web page http://localhost:8080

Internal Server Error

#<NoMethodError: undefined method `+' for nil:NilClass>
  icla-lint.cgi:56:in `block in <main>'

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Sun, Nov 15, 2015 at 10:58 PM, Craig L Russell
<cr...@oracle.com> wrote:
> I’ve followed the README in projects/whimsy and done what was asked.
>
> When I run ruby examples/board.rb I get the board from a couple of years ago, with Roy and Doug instead of Rich and David.

Yup.  I don't know the history or purpose of this LDAP 'service'
(that's what it is called in LDAP).  Nor do I know if the secretary
can change it.  It looks like the commands to do so would be:

% modify_appgroups.pl board --add=rbowen,ke4qqq
% modify_appgroups.pl board --rm=rfielding,cutting

> What else should I run to continue?

You didn't mention whether or not you were able to run it as a web
server.  If you have Apache httpd installed, you can run it as a CGI
script (takes a bit more to set up, but once done has the advantage
that every time you run you will pick up the latest changes), or as a
standalone server (to pick up a change, you will need to stop and
restart the server).

The next command you will want to try is:

ruby www/secretary/icla-lint.cgi

To get this to work you will need to install an additional gem
(ruby2js) and add a line to your ~/.whimsy file (for documents/iclas).

Once you get that working, here is a patch to add a button immediately
before the note (feel free to move the button to a different place).
Pushing the button won't do much (just issue an alert), but we can add
that later.

Index: icla-lint.cgi
===================================================================
--- icla-lint.cgi    (revision 968959)
+++ icla-lint.cgi    (working copy)
@@ -120,7 +120,11 @@
             _td name
           end

-          _td note
+          _td do
+            _button 'email', data_id: id
+            _span note
+          end
+
           _td comment2
         end
       end
@@ -142,5 +146,13 @@
         end
       end
     end
+
+    buttons = document.querySelectorAll('button')
+    for i in 0...buttons.length
+      buttons[i].addEventListener('click') do |event|
+        id = event.target.getAttribute('data-id')
+        alert(id)
+      end
+    end
   end
 end

- Sam Ruby

Re: Tooling for icla-lint

Posted by Craig L Russell <cr...@oracle.com>.
I’ve followed the README in projects/whimsy and done what was asked.

When I run ruby examples/board.rb I get the board from a couple of years ago, with Roy and Doug instead of Rich and David.

What else should I run to continue?

Craig

clr% ruby examples/board.rb
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta charset="utf-8"/>
    <title>List of ASF board members</title>
  </head>

  <body>
    <h1>List of ASF board members</h1>

    <table>
      <tr>
        <th>id</th>
        <th>name</th>
        <th>mail</th>
      </tr>

      <tr>
        <td>bdelacretaz</td>
        <td>Bertrand Delacretaz</td>
        <td>bdelacretaz@gmail.com</td>
      </tr>

      <tr>
        <td>cutting</td>
        <td>Doug Cutting</td>
        <td>cutting@gmail.com</td>
      </tr>

      <tr>
        <td>fielding</td>
        <td>Roy T. Fielding</td>
        <td>roy.fielding@gmail.com</td>
      </tr>

      <tr>
        <td>gstein</td>
        <td>Greg Stein</td>
        <td>gstein@gmail.com</td>
      </tr>

      <tr>
        <td>jim</td>
        <td>Jim Jagielski</td>
        <td>jim@jaguNET.com</td>
      </tr>

      <tr>
        <td>rubys</td>
        <td>Sam Ruby</td>
        <td>sa3ruby@gmail.com</td>
      </tr>

      <tr>
        <td>brett</td>
        <td>Brett Porter</td>
        <td>brett@porterclan.net</td>
      </tr>

      <tr>
        <td>mattmann</td>
        <td>Chris Mattmann</td>
        <td>mattmann@jpl.nasa.gov</td>
      </tr>

      <tr>
        <td>curcuru</td>
        <td>Shane Curcuru</td>
        <td>asf@shanecurcuru.org</td>
      </tr>
    </table>
  </body>
</html>

> On Nov 15, 2015, at 12:41 PM, Sam Ruby <ru...@intertwingly.net> wrote:
> 
> On Sun, Nov 15, 2015 at 2:53 PM, Craig L Russell
> <cr...@oracle.com> wrote:
>> I’d like to implement some tooling for the icla-lint page.
> 
> Sweet!
> 
>> What I’d like to do is to add buttons on each line:
>> (send email) this would send an email to the address in the iclas.txt entry requesting a new icla
>> 
>> (remove entry) this would remove the entry in iclas.txt and send an email
>> 
>> The idea is to contact folks with an iclas.txt entry whose icla cannot be found.
>> 
>> Is the library set up to facilitate this kind of stuff?
>> 
>> Where should I look for how to implement this?
> 
> I'd suggest that the first step is to get this tool either running
> directly on your machine, or on a VM.  If you would prefer doing this
> on a VM, I'll look at verifying that the vagrant instructions are up
> to date.  Otherwise, I would recommend that you start with the
> following:
> 
> https://svn.apache.org/repos/infra/infrastructure/trunk/projects/whimsy/README
> 
> If you get that working, to run the icla-lint file, you will need to
> install an additional gem: ruby2js, and you will need to update your
> ~/.whimsy file to point to a checkout of documents/iclas.
> 
> With this in place, you can run the icla-lint tool as a standalone server:
> 
>  ruby icla-lint.cgi --port=8080
> 
> ... or install it to run as a CGI under your existing Apache httpd server:
> 
>  ruby icla-lint.cgi --install=/Users/clr/Sites
> 
> (if you go with the latter, you may ultimately need to look into running suexec)
> 
>> Thanks,
>> 
>> Craig
>> 
>> Craig L Russell
>> Architect, Oracle
>> http://db.apache.org/jdo
>> 408 276-5638 mailto:Craig.Russell@oracle.com
>> P.S. A good JDO? O, Gasp!
> 
> - Sam Ruby

Craig L Russell
Architect, Oracle
http://db.apache.org/jdo
408 276-5638 mailto:Craig.Russell@oracle.com
P.S. A good JDO? O, Gasp!


Re: Tooling for icla-lint

Posted by Sam Ruby <ru...@intertwingly.net>.
On Sun, Nov 15, 2015 at 2:53 PM, Craig L Russell
<cr...@oracle.com> wrote:
> I’d like to implement some tooling for the icla-lint page.

Sweet!

> What I’d like to do is to add buttons on each line:
> (send email) this would send an email to the address in the iclas.txt entry requesting a new icla
>
> (remove entry) this would remove the entry in iclas.txt and send an email
>
> The idea is to contact folks with an iclas.txt entry whose icla cannot be found.
>
> Is the library set up to facilitate this kind of stuff?
>
> Where should I look for how to implement this?

I'd suggest that the first step is to get this tool either running
directly on your machine, or on a VM.  If you would prefer doing this
on a VM, I'll look at verifying that the vagrant instructions are up
to date.  Otherwise, I would recommend that you start with the
following:

https://svn.apache.org/repos/infra/infrastructure/trunk/projects/whimsy/README

If you get that working, to run the icla-lint file, you will need to
install an additional gem: ruby2js, and you will need to update your
~/.whimsy file to point to a checkout of documents/iclas.

With this in place, you can run the icla-lint tool as a standalone server:

  ruby icla-lint.cgi --port=8080

... or install it to run as a CGI under your existing Apache httpd server:

  ruby icla-lint.cgi --install=/Users/clr/Sites

(if you go with the latter, you may ultimately need to look into running suexec)

> Thanks,
>
> Craig
>
> Craig L Russell
> Architect, Oracle
> http://db.apache.org/jdo
> 408 276-5638 mailto:Craig.Russell@oracle.com
> P.S. A good JDO? O, Gasp!

- Sam Ruby