svn commit: r1829031 - /attic/site/docs/scripts/attic_filter.lua
Author: henkp Date: Fri Apr 13 05:05:42 2018 New Revision: 1829031 URL: http://svn.apache.org/viewvc?rev=1829031=rev Log: undeline link Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829031=1829030=1829031=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Fri Apr 13 05:05:42 2018 @@ -16,10 +16,12 @@ function output_filter(r) if not r.content_type:match(".*text/html.*") then return end -- add header: -local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname -local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look up real name) +-- get TLP part of hostname +local host = r.hostname:match("^([^.]+)") +-- Prettify (TODO: look up real name) +local name = host:gsub("^%l", string.upper) local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; -local sty2 = 'color:white' ; +local sty2 = 'color:white;text-decoration:underline' ; coroutine.yield ( ([[ Project %s has retired. For details please refer to its
Re: svn commit: r1829018 - /attic/site/docs/scripts/attic_filter.lua
On 13 April 2018 at 01:04, Henk P. Penningwrote: > On Fri, 13 Apr 2018, s...@apache.org wrote: > >> Date: Fri, 13 Apr 2018 01:31:26 +0200 >> From: s...@apache.org >> To: general@attic.apache.org >> Subject: svn commit: r1829018 - /attic/site/docs/scripts/attic_filter.lua > > > Sebb, > > please DON'T change this stuff ; you just broke it. I did not break it. It was svnpubsub that borked the workspace. I have reapplied the patch and it is now working. > HPP > >> Author: sebb >> Date: Thu Apr 12 23:31:26 2018 >> New Revision: 1829018 >> >> URL: http://svn.apache.org/viewvc?rev=1829018=rev >> Log: >> Prettify >> >> Modified: >>attic/site/docs/scripts/attic_filter.lua >> >> Modified: attic/site/docs/scripts/attic_filter.lua >> URL: >> http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829018=1829017=1829018=diff >> >> == >> --- attic/site/docs/scripts/attic_filter.lua (original) >> +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 23:31:26 2018 >> @@ -17,14 +17,15 @@ function output_filter(r) >> >> -- add header: >> local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname >> +local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look >> up real name) >> local sty1 = >> 'font-size:x-large;padding:15px;color:white;background:red;' ; >> local sty2 = 'color:white' ; >> coroutine.yield ( ([[ >> >> -Project %s is retired. See %s's >> +Project %s has retired. For details please refer to its >> https://attic.apache.org/projects/%s.html;> >> -attic page. >> - ]]):format(sty1, host, host, sty2, host) ) >> +Attic page. >> + ]]):format(sty1, name, sty2, host) ) >> -- spit out the actual page >> while bucket do >> coroutine.yield(bucket) >> >> >> > > _ > Henk P. Penning, ICT-beta R Uithof MG-403_/ \_ > Faculty of Science, Utrecht UniversityT +31 30 253 4106 / \_/ \ > Leuvenlaan 4, 3584CE Utrecht, NL F +31 30 253 4553 \_/ \_/ > http://www.staff.science.uu.nl/~penni101/ M penn...@uu.nl \_/
svn commit: r1829022 - /attic/site/docs/scripts/attic_filter.lua
Author: sebb Date: Fri Apr 13 00:26:27 2018 New Revision: 1829022 URL: http://svn.apache.org/viewvc?rev=1829022=rev Log: Reapply changes. Hope workspace behaves this time Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829022=1829021=1829022=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Fri Apr 13 00:26:27 2018 @@ -1,17 +1,31 @@ +--[[ + This is an output filter for HTML files + It adds a banner for projects that are flagged as in the attic. + + It is invoked by the tlp vhosts if the following directory exists: + /var/www/attic.apache.org/flagged/%{HTTP_HOST} + + See the tlp vhost definitions in puppet-infra data/nodes/(themis|tlp-eu-west).apache.org.yaml + + Note: This filter was introduced in April 2018, so not all projects in the Attic use this filter. + Previously the project websites themselves were changed. +]]-- + function output_filter(r) -- We only filter text/html types if not r.content_type:match(".*text/html.*") then return end -- add header: local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname +local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look up real name) local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; local sty2 = 'color:white' ; coroutine.yield ( ([[ -Project %s is retired. See %s's +Project %s has retired. For details please refer to its https://attic.apache.org/projects/%s.html;> -attic page. - ]]):format(sty1, host, host, sty2, host) ) +Attic page. + ]]):format(sty1, name, sty2, host) ) -- spit out the actual page while bucket do coroutine.yield(bucket)
Re: svn commit: r1829018 - /attic/site/docs/scripts/attic_filter.lua
On Fri, 13 Apr 2018, s...@apache.org wrote: Date: Fri, 13 Apr 2018 01:31:26 +0200 From: s...@apache.org To: general@attic.apache.org Subject: svn commit: r1829018 - /attic/site/docs/scripts/attic_filter.lua Sebb, please DON'T change this stuff ; you just broke it. HPP Author: sebb Date: Thu Apr 12 23:31:26 2018 New Revision: 1829018 URL: http://svn.apache.org/viewvc?rev=1829018=rev Log: Prettify Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829018=1829017=1829018=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 23:31:26 2018 @@ -17,14 +17,15 @@ function output_filter(r) -- add header: local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname +local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look up real name) local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; local sty2 = 'color:white' ; coroutine.yield ( ([[ -Project %s is retired. See %s's +Project %s has retired. For details please refer to its https://attic.apache.org/projects/%s.html;> -attic page. - ]]):format(sty1, host, host, sty2, host) ) +Attic page. + ]]):format(sty1, name, sty2, host) ) -- spit out the actual page while bucket do coroutine.yield(bucket) _ Henk P. Penning, ICT-beta R Uithof MG-403_/ \_ Faculty of Science, Utrecht UniversityT +31 30 253 4106 / \_/ \ Leuvenlaan 4, 3584CE Utrecht, NL F +31 30 253 4553 \_/ \_/ http://www.staff.science.uu.nl/~penni101/ M penn...@uu.nl \_/
svn commit: r1829021 - /attic/site/docs/scripts/attic_filter.lua
Author: sebb Date: Thu Apr 12 23:47:37 2018 New Revision: 1829021 URL: http://svn.apache.org/viewvc?rev=1829021=rev Log: Surely this was working? Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829021=1829020=1829021=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 23:47:37 2018 @@ -1,16 +1,3 @@ ---[[ - This is an output filter for HTML files - It adds a banner for projects that are flagged as in the attic. - - It is invoked by the tlp vhosts if the following directory exists: - /var/www/attic.apache.org/flagged/%{HTTP_HOST} - - See the tlp vhost definitions in puppet-infra data/nodes/(themis|tlp-eu-west).apache.org.yaml - - Note: This filter was introduced in April 2018, so not all projects in the Attic use this filter. - Previously the project websites themselves were changed. -]]-- - function output_filter(r) -- We only filter text/html types if not r.content_type:match(".*text/html.*") then return end
svn commit: r1829019 - /attic/site/docs/scripts/attic_filter.lua
Author: sebb Date: Thu Apr 12 23:35:27 2018 New Revision: 1829019 URL: http://svn.apache.org/viewvc?rev=1829019=rev Log: Revert - caused server error Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829019=1829018=1829019=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 23:35:27 2018 @@ -17,15 +17,14 @@ function output_filter(r) -- add header: local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname -local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look up real name) local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; local sty2 = 'color:white' ; coroutine.yield ( ([[ -Project %s has retired. For details please refer to its +Project %s is retired. See %s's https://attic.apache.org/projects/%s.html;> -Attic page. - ]]):format(sty1, name, sty2, host) ) +attic page. + ]]):format(sty1, host, host, sty2, host) ) -- spit out the actual page while bucket do coroutine.yield(bucket)
svn commit: r1829018 - /attic/site/docs/scripts/attic_filter.lua
Author: sebb Date: Thu Apr 12 23:31:26 2018 New Revision: 1829018 URL: http://svn.apache.org/viewvc?rev=1829018=rev Log: Prettify Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1829018=1829017=1829018=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 23:31:26 2018 @@ -17,14 +17,15 @@ function output_filter(r) -- add header: local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname +local name = host:gsub("^%l", string.upper) -- Prettify (TODO: look up real name) local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; local sty2 = 'color:white' ; coroutine.yield ( ([[ -Project %s is retired. See %s's +Project %s has retired. For details please refer to its https://attic.apache.org/projects/%s.html;> -attic page. - ]]):format(sty1, host, host, sty2, host) ) +Attic page. + ]]):format(sty1, name, sty2, host) ) -- spit out the actual page while bucket do coroutine.yield(bucket)
Re: attic_filter suggestions
On 12 April 2018 at 17:33, Henk P. Penningwrote: > On Thu, 12 Apr 2018, sebb wrote: > >> Date: Thu, 12 Apr 2018 17:53:42 +0200 >> From: sebb >> To: general@attic.apache.org >> Subject: attic_filter suggestions >> >> The new filter is great as it makes the Attic's job much simpler. > > > Yep ; it does ; a bit. > >> However it looks a bit odd to see the project name only in lower case; >> it would be nice if it showed the name in the correct format. > > > Work is still in progress ; we'll make it nicer, if easy and robust. > >> For many projects that just means capitalising the first letter. >> >> For others there could be a conversion table. >> >> Also, the marker is currently implemented as a directory containing an >> empty file of the same name, e.g. >> >> flagged/oltu.apache.org/oltu.apache.org > > > That is (for now) a safeguard ; what happened is that the > 'show-a-banner' condition : > > -d /var/attic.apache.org/flagged/%{HTTP_HOST} > > was mangeled by puppet and effectively was > > -d /var/attic.apache.org/flagged/ Yes, because % is special to puppet. > so, for a few minutes /every/ TLP got a banner ... > >> That seems a bit unnecessary; surely it would be enough to just have a >> file under flagged? > > > ... work is still in progress. The condition is now: It does not check the nested file I think which can just be deleted. Seems to me it would be better to just have files in the directory, i.e. change the condition to: > We will have to see if this works for all GHOST.apache.org sites ; > As is, some oltu.apache.org pages don't show the banner. For example? > Work will continue in about a week. > > Regards, > > HPP > > _ > Henk P. Penning, ICT-beta R Uithof MG-403_/ \_ > Faculty of Science, Utrecht UniversityT +31 30 253 4106 / \_/ \ > Leuvenlaan 4, 3584CE Utrecht, NL F +31 30 253 4553 \_/ \_/ > http://www.staff.science.uu.nl/~penni101/ M penn...@uu.nl \_/
Re: attic_filter suggestions
On Thu, 12 Apr 2018, sebb wrote: Date: Thu, 12 Apr 2018 17:53:42 +0200 From: sebbTo: general@attic.apache.org Subject: attic_filter suggestions The new filter is great as it makes the Attic's job much simpler. Yep ; it does ; a bit. However it looks a bit odd to see the project name only in lower case; it would be nice if it showed the name in the correct format. Work is still in progress ; we'll make it nicer, if easy and robust. For many projects that just means capitalising the first letter. For others there could be a conversion table. Also, the marker is currently implemented as a directory containing an empty file of the same name, e.g. flagged/oltu.apache.org/oltu.apache.org That is (for now) a safeguard ; what happened is that the 'show-a-banner' condition : -d /var/attic.apache.org/flagged/%{HTTP_HOST} was mangeled by puppet and effectively was -d /var/attic.apache.org/flagged/ so, for a few minutes /every/ TLP got a banner ... That seems a bit unnecessary; surely it would be enough to just have a file under flagged? ... work is still in progress. We will have to see if this works for all GHOST.apache.org sites ; As is, some oltu.apache.org pages don't show the banner. Work will continue in about a week. Regards, HPP _ Henk P. Penning, ICT-beta R Uithof MG-403_/ \_ Faculty of Science, Utrecht UniversityT +31 30 253 4106 / \_/ \ Leuvenlaan 4, 3584CE Utrecht, NL F +31 30 253 4553 \_/ \_/ http://www.staff.science.uu.nl/~penni101/ M penn...@uu.nl \_/
attic_filter suggestions
The new filter is great as it makes the Attic's job much simpler. However it looks a bit odd to see the project name only in lower case; it would be nice if it showed the name in the correct format. For many projects that just means capitalising the first letter. For others there could be a conversion table. Also, the marker is currently implemented as a directory containing an empty file of the same name, e.g. flagged/oltu.apache.org/oltu.apache.org That seems a bit unnecessary; surely it would be enough to just have a file under flagged?
svn commit: r1828988 - /attic/site/docs/scripts/attic_filter.lua
Author: sebb Date: Thu Apr 12 15:38:20 2018 New Revision: 1828988 URL: http://svn.apache.org/viewvc?rev=1828988=rev Log: Docn Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1828988=1828987=1828988=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 15:38:20 2018 @@ -1,3 +1,16 @@ +--[[ + This is an output filter for HTML files + It adds a banner for projects that are flagged as in the attic. + + It is invoked by the tlp vhosts if the following directory exists: + /var/www/attic.apache.org/flagged/%{HTTP_HOST} + + See the tlp vhost definitions in puppet-infra data/nodes/(themis|tlp-eu-west).apache.org.yaml + + Note: This filter was introduced in April 2018, so not all projects in the Attic use this filter. + Previously the project websites themselves were changed. +]]-- + function output_filter(r) -- We only filter text/html types if not r.content_type:match(".*text/html.*") then return end
svn commit: r1828969 - /attic/site/docs/flagged/oltu.eu.apache.org/
Author: henkp Date: Thu Apr 12 10:38:22 2018 New Revision: 1828969 URL: http://svn.apache.org/viewvc?rev=1828969=rev Log: -= flagged/oltu.eu.apache.org Removed: attic/site/docs/flagged/oltu.eu.apache.org/
svn commit: r1828968 - /attic/site/docs/flagged/oltu.apache.org/oltu.apache.org
Author: henkp Date: Thu Apr 12 10:26:27 2018 New Revision: 1828968 URL: http://svn.apache.org/viewvc?rev=1828968=rev Log: += flagged/oltu.apache.org/oltu.apache.org Added: attic/site/docs/flagged/oltu.apache.org/oltu.apache.org Added: attic/site/docs/flagged/oltu.apache.org/oltu.apache.org URL: http://svn.apache.org/viewvc/attic/site/docs/flagged/oltu.apache.org/oltu.apache.org?rev=1828968=auto == (empty)
svn commit: r1828964 - /attic/site/docs/flagged/oltu.eu.apache.org/
Author: henkp Date: Thu Apr 12 09:43:17 2018 New Revision: 1828964 URL: http://svn.apache.org/viewvc?rev=1828964=rev Log: testing Added: attic/site/docs/flagged/oltu.eu.apache.org/
svn commit: r1828963 - /attic/site/velocity.log
Author: sebb Date: Thu Apr 12 09:30:12 2018 New Revision: 1828963 URL: http://svn.apache.org/viewvc?rev=1828963=rev Log: Does not belong in SVN. Not sure why it was ever committed, as it is listed in svn:ignore Removed: attic/site/velocity.log
svn commit: r1828955 - /attic/site/docs/scripts/attic_filter.lua
Author: henkp Date: Thu Apr 12 08:16:04 2018 New Revision: 1828955 URL: http://svn.apache.org/viewvc?rev=1828955=rev Log: style attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua Modified: attic/site/docs/scripts/attic_filter.lua URL: http://svn.apache.org/viewvc/attic/site/docs/scripts/attic_filter.lua?rev=1828955=1828954=1828955=diff == --- attic/site/docs/scripts/attic_filter.lua (original) +++ attic/site/docs/scripts/attic_filter.lua Thu Apr 12 08:16:04 2018 @@ -4,13 +4,14 @@ function output_filter(r) -- add header: local host = r.hostname:match("^([^.]+)") -- get TLP part of hostname -coroutine.yield(([[ - -This project has retired! See -attic.apache.org/%s.html. - -]]):format(host, host)) - +local sty1 = 'font-size:x-large;padding:15px;color:white;background:red;' ; +local sty2 = 'color:white' ; +coroutine.yield ( ([[ + +Project %s is retired. See %s's +https://attic.apache.org/projects/%s.html;> +attic page. + ]]):format(sty1, host, host, sty2, host) ) -- spit out the actual page while bucket do coroutine.yield(bucket)