Hello community,
here is the log from the commit of package perl-HTML-Clean for openSUSE:Factory
checked in at 2019-08-28 18:37:49
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-HTML-Clean (Old)
and /work/SRC/openSUSE:Factory/.perl-HTML-Clean.new.7948 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-HTML-Clean"
Wed Aug 28 18:37:49 2019 rev:22 rq:726690 version:0.9
Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-HTML-Clean/perl-HTML-Clean.changes
2017-08-24 18:52:33.328097883 +0200
+++
/work/SRC/openSUSE:Factory/.perl-HTML-Clean.new.7948/perl-HTML-Clean.changes
2019-08-28 18:37:52.173258796 +0200
@@ -1,0 +2,15 @@
+Tue Aug 27 08:59:08 UTC 2019 - Pedro Monreal Gonzalez
<[email protected]>
+
+- Drop perl-HTML-Clean-0.8-IO.diff as upstream moved to IO::File
+
+-------------------------------------------------------------------
+Thu Aug 22 05:08:31 UTC 2019 - Stephan Kulow <[email protected]>
+
+- updated to 0.9
+ see /usr/share/doc/packages/perl-HTML-Clean/Changes
+
+ 0.9 Tue Aug 20 09:24 PDT 2019
+
+ - Fix warnings - use IO::File instead deprecated module IO.
+
+-------------------------------------------------------------------
Old:
----
HTML-Clean-0.8.tar.gz
perl-HTML-Clean-0.8-IO.diff
New:
----
HTML-Clean-0.9.tar.gz
cpanspec.yml
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-HTML-Clean.spec ++++++
--- /var/tmp/diff_new_pack.2vKmvh/_old 2019-08-28 18:37:53.657258538 +0200
+++ /var/tmp/diff_new_pack.2vKmvh/_new 2019-08-28 18:37:53.661258538 +0200
@@ -1,7 +1,7 @@
#
# spec file for package perl-HTML-Clean
#
-# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2019 SUSE LINUX GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@@ -12,70 +12,62 @@
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
-# Please submit bugfixes or comments via http://bugs.opensuse.org/
+# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: perl-HTML-Clean
-BuildRequires: perl
-BuildRequires: perl-macros
-Version: 0.8
+Version: 0.9
Release: 0
-Provides: HTML-Clean
-Conflicts: perlmod
-Url: http://cpan.org/modules/by-module/HTML/
-Source: HTML-Clean-%{version}.tar.gz
-Patch: %{name}-%{version}-IO.diff
+%define cpan_name HTML-Clean
Summary: Cleans up HTML code for web browsers, not humans
License: Artistic-1.0
Group: Development/Libraries/Perl
+Url: https://metacpan.org/release/%{cpan_name}
+Source0:
https://cpan.metacpan.org/authors/id/A/AZ/AZJADFTRE/%{cpan_name}-%{version}.tar.gz
+Source1: cpanspec.yml
+BuildArch: noarch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
+BuildRequires: perl
+BuildRequires: perl-macros
%{perl_requires}
%description
-The majority of the web pages of the internet today are much larger
-than they need to be. The reason for this is that HTML tends to be
-stored in a human readable format, with indenting, newlines and
-comments.
+The HTML::Clean module encapsulates a number of common techniques for
+minimizing the size of HTML files. You can typically save between 10% and
+50% of the size of a HTML file using these methods. It provides the
+following features:
-However, all of these comments, whitespace etc. are ignored by the
-browser, and needlessly lengthen download times.
+* Remove unneeded whitespace (begining of line, etc)
-Second, many people are using WYSIWYG HTML editors these days. This
-makes creating content easy. However these editors can cause a number
-of compatibility problems by tying themselves to a particular browser
-or operating system.
+* Remove unneeded META elements.
+* Remove HTML comments (except for styles, javascript and SSI)
+* Replace tags with equivilant shorter tags (<strong> --> <b>)
-Authors:
---------
- Paul Lindner <[email protected]>
+* etc.
+
+The entire proces is configurable, so you can pick and choose what you want
+to clean.
%prep
-%setup -n HTML-Clean-%{version} -q
-%patch
+%setup -q -n %{cpan_name}-%{version}
%build
-perl Makefile.PL
-make %{?_smp_mflags} all
+perl Makefile.PL INSTALLDIRS=vendor
+make %{?_smp_mflags}
+
+%check
make test
%install
-rm -rf $RPM_BUILD_ROOT
-make DESTDIR=$RPM_BUILD_ROOT install_vendor
+%perl_make_install
%perl_process_packlist
+%perl_gen_filelist
-%clean
-rm -rf $RPM_BUILD_ROOT
-
-%files
-%defattr(-, root, root)
-%doc TODO Changes README
-%doc %{_mandir}/man?/*
-%{perl_vendorarch}/auto/HTML
-%{perl_vendorlib}/auto/HTML
-%{perl_vendorlib}/HTML
-%{_bindir}/htmlclean
+%files -f %{name}.files
+%defattr(-,root,root,755)
+%doc Changes README TODO
%changelog
++++++ HTML-Clean-0.8.tar.gz -> HTML-Clean-0.9.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/HTML-Clean-0.8/Changes new/HTML-Clean-0.9/Changes
--- old/HTML-Clean-0.8/Changes 2000-09-05 23:18:32.000000000 +0200
+++ new/HTML-Clean-0.9/Changes 2019-08-20 08:30:29.000000000 +0200
@@ -1,17 +1,21 @@
Revision history for Perl module HTML::Clean
--------------------------------------------
+0.9 Tue Aug 20 09:24 PDT 2019
+
+ - Fix warnings - use IO::File instead deprecated module IO.
+
0.8 Tue Sep 5 08:02:05 PDT 2000
- Fix dequote regex to be stricter. Make sure quote/double quote
match, only use alpha as the paramater name. Reported by
Renzo Tom�.
- - Removed regexes for removing space within tags and border=0 case.
+ - Removed regexes for removing space within tags and border=0 case.
This Causes text in attributes to fail, and table borders get
messed up on IE. Reported by Gregory Stark.
- Fix for improper parsing of emptytags from Jens Quade.
-
+
- Fix from Tobias Weber to clean javascript
@@ -24,7 +28,7 @@
- Apply same compatibility option to Verdana and Futura font.
-0.6 Fri Apr 23 14:03:30 MET DST 1999
+0.6 Fri Apr 23 14:03:30 MET DST 1999
- Now removes whitespace from within tags, like this:
<table > becomes <table>
@@ -45,19 +49,19 @@
'looks' correct.
-0.5 Mon Feb 22 13:12:32 MET 1999
+0.5 Mon Feb 22 13:12:32 MET 1999
- Now removes empty tag sets. For instance <i><b></b></i> is now
eliminated. (From Philippe Verdret)
- Cleans up excess space in inline javascript functions. Does
- a better job of removing javascript comments. (idea from
+ a better job of removing javascript comments. (idea from
Phillippe Verdret)
- Added a larger list of default color names to replace.
-0.4 Mon Jan 18 15:10:35 MET 1999
+0.4 Mon Jan 18 15:10:35 MET 1999
- Bug Fix: use upper case filehandle names (from numerous people..)
- Enabled level and options (patch from Mike Heins)
@@ -73,12 +77,12 @@
- More documentation
-0.3 Mon Jan 11 14:05:15 MET 1999
+0.3 Mon Jan 11 14:05:15 MET 1999
- Fixed serious htmlclean script bug.
- Added a little more documentation.
-
-0.2 Tue Dec 29 10:13:16 MET 1998
+
+0.2 Tue Dec 29 10:13:16 MET 1998
- expanded number of strip options
- First CPAN release..
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn'
'--exclude=.svnignore' old/HTML-Clean-0.8/lib/HTML/Clean.pm
new/HTML-Clean-0.9/lib/HTML/Clean.pm
--- old/HTML-Clean-0.8/lib/HTML/Clean.pm 2000-09-06 19:57:26.000000000
+0200
+++ new/HTML-Clean-0.9/lib/HTML/Clean.pm 2019-08-20 08:36:36.000000000
+0200
@@ -1,7 +1,7 @@
package HTML::Clean;
use Carp;
-use IO;
+use IO::File;
use Fcntl;
use strict;
require 5.004;
@@ -14,7 +14,7 @@
# Items to export to callers namespace
@EXPORT = qw();
-$VERSION = '0.8';
+$VERSION = '0.9';
=head1 NAME
@@ -25,7 +25,7 @@
use HTML::Clean;
$h = new HTML::Clean($filename); # or..
$h = new HTML::Clean($htmlcode);
-
+
$h->compat();
$h->strip();
$data = $h->data();
@@ -87,7 +87,7 @@
my $class = ref($this) || $this;
my $self = {};
bless $self, $class;
-
+
my $data = shift;
my $level = shift;
@@ -101,8 +101,8 @@
return undef;
}
}
-
-
+
+
#
# Set up the data in the self hash..
#
@@ -110,7 +110,7 @@
=head2 $h->initialize($dataorfile)
This function allows you to reinitialize the HTML data used by the
-current object. This is useful if you are processing many files.
+current object. This is useful if you are processing many files.
$dataorfile has the same usage as the new method.
@@ -122,20 +122,20 @@
my($self, $data) = @_;
$self->{'DATA'} = undef;
- # Not defined? Just return true.
- return(1) if (!$data);
+ # Not defined? Just return true.
+ return(1) if (!$data);
# Check if it's a ref
if (ref($data)) {
$self->{DATA} = $data;
return(1);
}
-
+
# Newline char, really an error, but just go with it..
if ($data =~ /\n/) {
$self->{'DATA'} = \$data;
}
-
+
# No newline? Must be a filename
if (-f $data) {
my $storage;
@@ -187,7 +187,7 @@
my($comment) = @_;
$_ = $comment;
-
+
# Server side include
return($comment) if (m,^<!--\#,si);
@@ -214,7 +214,7 @@
$js =~ s,\s+//.*?\n,\n,sig;
# insure javascript is hidden
-
+
if ($js =~ m,<!--,) {
$js =~ s,</script>,// -->\n</script>,si;
}
@@ -228,7 +228,7 @@
# remove excess whitespace at the beginning and end of lines
$js =~ s,\s*\n+\s*,\n,sig;
-
+
# braces/semicolon at end of line, join next line
$js =~ s,([;{}])\n,$1,sig;
@@ -263,7 +263,7 @@
return($c);
}
-# For replacing entities with numerics
+# For replacing entities with numerics
use vars qw/ %_ENTITIES/;
%_ENTITIES = (
'Agrave' => 192,
@@ -357,11 +357,11 @@
=item parameterized values
- meta Takes a space separated list of meta tags to remove,
+ meta Takes a space separated list of meta tags to remove,
default "GENERATOR FORMATTER"
emptytags Takes a space separated list of tags to remove when there is no
- content between the start and end tag, like this: <b></b>.
+ content between the start and end tag, like this: <b></b>.
The default is 'b i font center'
=back
@@ -369,13 +369,13 @@
=cut
use vars qw/
- $do_whitespace
- $do_shortertags
- $do_meta
- $do_blink
- $do_contenttype
- $do_comments
- $do_entities
+ $do_whitespace
+ $do_shortertags
+ $do_meta
+ $do_blink
+ $do_contenttype
+ $do_comments
+ $do_entities
$do_dequote
$do_defcolor
$do_emptytags
@@ -383,7 +383,7 @@
$do_htmldefaults
$do_lowercasetags
$do_defbaseurl
- /;
+ /;
$do_whitespace = 1;
$do_shortertags = 1;
@@ -406,7 +406,7 @@
my $h = $self->{'DATA'};
my $level = $self->{'LEVEL'};
- # Select a set of options based on $level, and then modify based on
+ # Select a set of options based on $level, and then modify based on
# user supplied options.
_level_defaults($level);
@@ -575,10 +575,10 @@
$do_comments = ($level > 3) ? 1 : 0;
$do_dequote = ($level > 3) ? 1 : 0;
$do_defcolor = ($level > 3) ? 1 : 0;
- $do_emptytags = ($level > 3) ? 'b i font center' : 0;
+ $do_emptytags = ($level > 3) ? 'b i font center' : 0;
$do_javascript = ($level > 3) ? 1 : 0;
- $do_htmldefaults = ($level > 3) ? 1 : 0;
- $do_lowercasetags = ($level > 3) ? 1 : 0;
+ $do_htmldefaults = ($level > 3) ? 1 : 0;
+ $do_lowercasetags = ($level > 3) ? 1 : 0;
# higher levels reserved for more intensive optimizations.
}
@@ -627,7 +627,7 @@
$tag =~ s/>/ alt="">/ if ($tag !~ /alt=/i);
return($tag);
-}
+}
=head2 defrontpage();
@@ -670,7 +670,7 @@
=item Distribution Site - http://people.itu.int/~lindner/
-=back
+=back
=head1 AUTHORS
++++++ cpanspec.yml ++++++
---
#description_paragraphs: 3
#description: |-
# override description from CPAN
#summary: override summary from CPAN
#no_testing: broken upstream
#sources:
# - source1
# - source2
#patches:
# foo.patch: -p1
# bar.patch:
#preamble: |-
# BuildRequires: gcc-c++
#post_prep: |-
# hunspell=`pkg-config --libs hunspell | sed -e 's,-l,,; s, *,,g'`
# sed -i -e "s,hunspell-X,$hunspell," t/00-prereq.t Makefile.PL
#post_build: |-
# rm unused.files
#post_install: |-
# sed on %{name}.files
#license: SUSE-NonFree
#skip_noarch: 1
#custom_build: |-
#./Build build flags=%{?_smp_mflags} --myflag
#custom_test: |-
#startserver && make test
#ignore_requires: Bizarre::Module