r66290 - in /trunk/libtemplate-plugin-javascript-perl: Changes META.yml debian/changelog debian/control debian/copyright debian/source/ debian/source/format lib/Template/Plugin/JavaScript.pm t/01_test.t
jawnsy-guest at users.alioth.debian.org
jawnsy-guest at users.alioth.debian.org
Sat Dec 25 01:14:46 UTC 2010
Author: jawnsy-guest
Date: Sat Dec 25 01:14:37 2010
New Revision: 66290
URL: http://svn.debian.org/wsvn/pkg-perl/?sc=1&rev=66290
Log:
* New upstream release
* Standards-Version 3.9.1 (no changes)
* Use new 3.0 (quilt) source format
Added:
trunk/libtemplate-plugin-javascript-perl/debian/source/
trunk/libtemplate-plugin-javascript-perl/debian/source/format
Modified:
trunk/libtemplate-plugin-javascript-perl/Changes
trunk/libtemplate-plugin-javascript-perl/META.yml
trunk/libtemplate-plugin-javascript-perl/debian/changelog
trunk/libtemplate-plugin-javascript-perl/debian/control
trunk/libtemplate-plugin-javascript-perl/debian/copyright
trunk/libtemplate-plugin-javascript-perl/lib/Template/Plugin/JavaScript.pm
trunk/libtemplate-plugin-javascript-perl/t/01_test.t
Modified: trunk/libtemplate-plugin-javascript-perl/Changes
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/Changes?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/Changes (original)
+++ trunk/libtemplate-plugin-javascript-perl/Changes Sat Dec 25 01:14:37 2010
@@ -1,4 +1,7 @@
Revision history for Perl extension Template::Plugin::JavaScript
+
+0.02 Wed Dec 15 11:42:31 PST 2010
+ - Escapes HTML tags too (cho45)
0.01 Fri Aug 20 01:00:39 2004
- original version
Modified: trunk/libtemplate-plugin-javascript-perl/META.yml
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/META.yml?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/META.yml (original)
+++ trunk/libtemplate-plugin-javascript-perl/META.yml Sat Dec 25 01:14:37 2010
@@ -1,12 +1,22 @@
-# http://module-build.sourceforge.net/META-spec.html
-#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX#
-name: Template-Plugin-JavaScript
-version: 0.01
-version_from: lib/Template/Plugin/JavaScript.pm
-installdirs: site
+--- #YAML:1.0
+name: Template-Plugin-JavaScript
+version: 0.02
+abstract: ~
+author: []
+license: unknown
+distribution_type: module
+configure_requires:
+ ExtUtils::MakeMaker: 0
+build_requires:
+ ExtUtils::MakeMaker: 0
requires:
- Template: 0
- Test::More: 0.32
-
-distribution_type: module
-generated_by: ExtUtils::MakeMaker version 6.17
+ Template: 0
+ Test::More: 0.32
+no_index:
+ directory:
+ - t
+ - inc
+generated_by: ExtUtils::MakeMaker version 6.56
+meta-spec:
+ url: http://module-build.sourceforge.net/META-spec-v1.4.html
+ version: 1.4
Modified: trunk/libtemplate-plugin-javascript-perl/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/debian/changelog?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/debian/changelog (original)
+++ trunk/libtemplate-plugin-javascript-perl/debian/changelog Sat Dec 25 01:14:37 2010
@@ -1,4 +1,9 @@
-libtemplate-plugin-javascript-perl (0.01-2) UNRELEASED; urgency=low
+libtemplate-plugin-javascript-perl (0.02-1) UNRELEASED; urgency=low
+
+ [ Jonathan Yu ]
+ * New upstream release
+ * Standards-Version 3.9.1 (no changes)
+ * Use new 3.0 (quilt) source format
[ Salvatore Bonaccorso ]
* debian/control: Changed: Replace versioned (build-)dependency on
@@ -8,7 +13,7 @@
[ Ryan Niebur ]
* Update jawnsy's email address
- -- Ryan Niebur <ryanryan52 at gmail.com> Tue, 01 Sep 2009 21:19:45 -0700
+ -- Jonathan Yu <jawnsy at cpan.org> Fri, 24 Dec 2010 20:30:00 -0500
libtemplate-plugin-javascript-perl (0.01-1) unstable; urgency=low
Modified: trunk/libtemplate-plugin-javascript-perl/debian/control
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/debian/control?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/debian/control (original)
+++ trunk/libtemplate-plugin-javascript-perl/debian/control Sat Dec 25 01:14:37 2010
@@ -6,7 +6,7 @@
Maintainer: Debian Perl Group <pkg-perl-maintainers at lists.alioth.debian.org>
Uploaders: Maximilian Gaà <mxey at cloudconnected.org>,
Jonathan Yu <jawnsy at cpan.org>
-Standards-Version: 3.8.2
+Standards-Version: 3.9.1
Homepage: http://search.cpan.org/dist/Template-Plugin-JavaScript/
Vcs-Svn: svn://svn.debian.org/pkg-perl/trunk/libtemplate-plugin-javascript-perl/
Vcs-Browser: http://svn.debian.org/viewsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/
Modified: trunk/libtemplate-plugin-javascript-perl/debian/copyright
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/debian/copyright?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/debian/copyright (original)
+++ trunk/libtemplate-plugin-javascript-perl/debian/copyright Sat Dec 25 01:14:37 2010
@@ -1,13 +1,11 @@
-Format-Specification:
- http://wiki.debian.org/Proposals/CopyrightFormat?action=recall&rev=196
-Upstream-Maintainer: Tatsuhiko Miyagawa <miyagawa at bulknews.net>
-Upstream-Source: http://search.cpan.org/dist/Template-Plugin-JavaScript/
-Upstream-Name: Template-Plugin-JavaScript
+Format-Specification: http://svn.debian.org/wsvn/dep/web/deps/dep5.mdwn?op=file&rev=135
+Maintainer: Tatsuhiko Miyagawa <miyagawa at bulknews.net>
+Source: http://search.cpan.org/dist/Template-Plugin-JavaScript/
+Name: Template-Plugin-JavaScript
Files: *
-Copyright: 2004, Tatsuhiko Miyagawa <miyagawa at bulknews.net>
-License-Alias: Perl
-License: Artistic | GPL-1+
+Copyright: 2004-2010, Tatsuhiko Miyagawa <miyagawa at bulknews.net>
+License: Artistic or GPL-1+
X-Comment: Rationale from the author was:
All of my modules available at http://search.cpan.org/~miyagawa/ with the
statement "AUTHOR: Tatsuhiko Miyagawa" are, unless otherwise noted,
@@ -16,20 +14,22 @@
The exact year comes from the CPAN upload date.
Files: debian/*
-Copyright: 2009, Jonathan Yu <jawnsy at cpan.org>
+Copyright: 2009-2010, Jonathan Yu <jawnsy at cpan.org>
2009, Maximilian Gaà <mxey at cloudconnected.org>
-License: Artistic | GPL-1+
+License: Artistic or GPL-1+
License: Artistic
- This program is free software; you can redistribute it and/or modify
- it under the terms of the Artistic License, which comes with Perl.
- On Debian GNU/Linux systems, the complete text of the Artistic License
- can be found in `/usr/share/common-licenses/Artistic'
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the Artistic License, which comes with Perl.
+ .
+ On Debian systems, the complete text of the Artistic License can be
+ found in `/usr/share/common-licenses/Artistic'.
License: GPL-1+
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
- On Debian GNU/Linux systems, the complete text of the GNU General
- Public License can be found in `/usr/share/common-licenses/GPL'
+ This program is free software; you can redistribute it and/or modify
+ it under the terms of the GNU General Public License as published by
+ the Free Software Foundation; either version 1, or (at your option)
+ any later version.
+ .
+ On Debian systems, the complete text of version 1 of the GNU General
+ Public License can be found in `/usr/share/common-licenses/GPL-1'.
Added: trunk/libtemplate-plugin-javascript-perl/debian/source/format
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/debian/source/format?rev=66290&op=file
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/debian/source/format (added)
+++ trunk/libtemplate-plugin-javascript-perl/debian/source/format Sat Dec 25 01:14:37 2010
@@ -1,0 +1,1 @@
+3.0 (quilt)
Modified: trunk/libtemplate-plugin-javascript-perl/lib/Template/Plugin/JavaScript.pm
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/lib/Template/Plugin/JavaScript.pm?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/lib/Template/Plugin/JavaScript.pm (original)
+++ trunk/libtemplate-plugin-javascript-perl/lib/Template/Plugin/JavaScript.pm Sat Dec 25 01:14:37 2010
@@ -2,7 +2,7 @@
use strict;
use vars qw($VERSION);
-$VERSION = '0.01';
+$VERSION = '0.02';
require Template::Plugin;
use base qw(Template::Plugin);
@@ -21,11 +21,15 @@
local $_ = shift;
return '' unless defined $_;
+ s!\\!\\\\!g;
s!(['"])!\\$1!g;
s!\n!\\n!g;
s!\f!\\f!g;
s!\r!\\r!g;
s!\t!\\t!g;
+ s!<!\\x3c!g;
+ s!>!\\x3e!g;
+ s!&!\\x26!g;
$_;
}
Modified: trunk/libtemplate-plugin-javascript-perl/t/01_test.t
URL: http://svn.debian.org/wsvn/pkg-perl/trunk/libtemplate-plugin-javascript-perl/t/01_test.t?rev=66290&op=diff
==============================================================================
--- trunk/libtemplate-plugin-javascript-perl/t/01_test.t (original)
+++ trunk/libtemplate-plugin-javascript-perl/t/01_test.t Sat Dec 25 01:14:37 2010
@@ -1,5 +1,7 @@
use strict;
use Template::Test;
+
+use lib 'lib';
test_expect(\*DATA);
@@ -12,3 +14,32 @@
--expect--
document.write("\nHere\'s some text going on.\n");
+--test--
+[% USE JavaScript -%]
+document.write("[% FILTER js %]
+You & I
+[% END %]");
+--expect--
+document.write("\nYou \x26 I\n");
+
+--test--
+[% USE JavaScript -%]
+var t = "[% FILTER js %]
+\"+alert(1)//
+[% END %]";
+--expect--
+var t = "\n\\\"+alert(1)//\n";
+
+--test--
+[% USE JavaScript -%]
+<script type="text/javascript">
+var t = "[% FILTER js %]
+\"</script><script>
+alert(1)//
+[% END %]";
+</script>
+--expect--
+<script type="text/javascript">
+var t = "\n\\\"\x3c/script\x3e\x3cscript\x3e\nalert(1)//\n";
+</script>
+
More information about the Pkg-perl-cvs-commits
mailing list