From: Jakub Bogusz Date: Thu, 1 Nov 2012 09:11:47 +0000 (+0100) Subject: - new X-Git-Tag: auto/th/perl-HTML-FormatText-WithLinks-AndTables-0.02-1 X-Git-Url: http://git.pld-linux.org/gitweb.cgi?a=commitdiff_plain;h=99062c03c20b9e01930793d59e376ffb77374251;p=packages%2Fperl-HTML-FormatText-WithLinks-AndTables.git - new --- 99062c03c20b9e01930793d59e376ffb77374251 diff --git a/perl-HTML-FormatText-WithLinks-AndTables.spec b/perl-HTML-FormatText-WithLinks-AndTables.spec new file mode 100644 index 0000000..2b96e79 --- /dev/null +++ b/perl-HTML-FormatText-WithLinks-AndTables.spec @@ -0,0 +1,79 @@ +# +# Conditional build: +%bcond_without tests # do not perform "make test" +# +%define pdir HTML +%define pnam FormatText-WithLinks-AndTables +%include /usr/lib/rpm/macros.perl +Summary: HTML::FormatText::WithLinks::AndTables - Converts HTML to Text with tables in tact +Summary(pl.UTF-8): HTML::FormatText::WithLinks::AndTables - konwersja HTML-a do tekstu z tabelkami +Name: perl-HTML-FormatText-WithLinks-AndTables +Version: 0.02 +Release: 1 +# same as perl +License: GPL v1+ or Artistic +Group: Development/Languages/Perl +Source0: http://www.cpan.org/modules/by-module/HTML/%{pdir}-%{pnam}-%{version}.tar.gz +# Source0-md5: 804146aa9e49a5b1af4f63fecd9b0c28 +URL: http://search.cpan.org/dist/HTML-FormatText-WithLinks-AndTables/ +BuildRequires: perl-ExtUtils-MakeMaker +BuildRequires: perl-devel >= 1:5.8.0 +BuildRequires: rpm-perlprov >= 4.1-13 +%if %{with tests} +BuildRequires: perl-HTML-FormatText-WithLinks +BuildRequires: perl-HTML-Tree +BuildRequires: perl-Test-Simple +%endif +BuildArch: noarch +BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) + +%description +This module was inspired by HTML::FormatText::WithLinks which has +proven to be a useful `lynx -dump` work-alike. However one frustration +was that no other HTML converters had the ability to deal affectively +with HTML s. This module can in a rudimentary sense do so. The +aim was to provide facility to take a simple HTML based email +template, and to also convert it to text with the
structure in +tact for inclusion as "multipart/alternative" content. Further, it +will preserve both the formatting specified by the
tag's "align" +attribute, and will also preserve multiline text inside of a +element provided it is broken using
tags. + +%description -l pl.UTF-8 +Ten moduł jest zainspirowany modułem HTML::FormatText::WithLinks, +który okazał się przydatnym odpowiednikiem polecenia "lynx -dump". +Jednak żaden dotychczasowy konwerter HTML-a nie mógł efektywnie +poradzić sobie z elementami HTML . Ten moduł potrafi to w +podstawowym zakresie. Celem była możliwość przekazania prostego +szablonu wiadomości elektronicznej w HTML-u i przekształcenie jej do +tekstu wraz ze strukturą
, aby można ją było umieścić w treści +multipart/alternative. Co więcej, moduł zachowuje formatowanie +określone atrybutem "align" znacznika
oraz wieloliniowy tekst +wewnątrz elementu - pod warunkiem, że jest złamany przy użyciu +znaczników
. + +%prep +%setup -q -n %{pdir}-%{pnam} + +%build +%{__perl} Makefile.PL \ + INSTALLDIRS=vendor +%{__make} + +%{?with_tests:%{__make} test} + +%install +rm -rf $RPM_BUILD_ROOT + +%{__make} pure_install \ + DESTDIR=$RPM_BUILD_ROOT + +%clean +rm -rf $RPM_BUILD_ROOT + +%files +%defattr(644,root,root,755) +%doc Changes README +%dir %{perl_vendorlib}/HTML/FormatText/WithLinks +%{perl_vendorlib}/HTML/FormatText/WithLinks/AndTables.pm +%{_mandir}/man3/HTML::FormatText::WithLinks::AndTables.3pm*