1
0
perl-App-Nopaste/perl-App-Nopaste.spec

121 lines
3.8 KiB
RPMSpec

# vim: set sw=4 ts=4 et nu:
# norootforbuild
Name: perl-App-Nopaste
Version: 0.23
Release: 0
Summary: Easy access to any pastebin
Source: http://search.cpan.org/CPAN/authors/id/S/SA/SARTAK/App-Nopaste-%{version}.tar.gz
Source1: SusePaste.pm
URL: http://search.cpan.org/dist/App-Nopaste
Group: Development/Libraries/Perl
License: Perl License
BuildRoot: %{_tmppath}/build-%{name}-%{version}
%{perl_requires}
BuildRequires: perl
BuildRequires: perl-macros
BuildRequires: make
BuildRequires: perl(ExtUtils::MakeMaker) >= 6.42
BuildRequires: perl(MooseX::Getopt) >= 0.17
BuildRequires: perl(Module::Pluggable)
BuildRequires: perl(WWW::Mechanize)
BuildRequires: perl(Moose) >= 0.74
BuildRequires: perl(Clipboard)
BuildRequires: perl(WWW::Pastebin::PastebinCom::Create)
BuildRequires: perl(Config::GitLike)
BuildRequires: perl(File::Temp)
BuildRequires: perl(File::Spec)
Requires: perl(MooseX::Getopt) >= 0.17
Requires: perl(Module::Pluggable)
Requires: perl(WWW::Mechanize)
Requires: perl(Moose) >= 0.74
Recommends: perl(Clipboard)
Recommends: perl(WWW::Pastebin::PastebinCom::Create)
Recommends: perl(Config::GitLike)
Recommends: perl(File::Temp)
Recommends: perl(File::Spec)
%description
Pastebins (also known as nopaste sites) let you post text, usually code,
for public viewing. They're used a lot in IRC channels to show code that
would normally be too long to give directly in the channel (hence the name
nopaste).
Each pastebin is slightly different. When one pastebin goes down (I'm
looking at you, <http://paste.husk.org>), then you have to find a new one.
And if you usually use a script to publish text, then it's too much
hassle.
This module aims to smooth out the differences between pastebins, and
provides redundancy: if one site doesn't work, it just tries a different
one.
It's also modular: you only need to put on CPAN a
App::Nopaste::Service::Foo module and anyone can begin using it.
%package -n nopaste
Summary: Easy access to any pastebin
License: Perl License
Group: Productivity/Networking/Web/Utilities
Requires: %{name} = %{version}
%if 0%{?suse_version} >= 1120
BuildArch: noarch
%endif
%description -n nopaste
Pastebins (also known as nopaste sites) let you post text, usually code,
for public viewing. They're used a lot in IRC channels to show code that
would normally be too long to give directly in the channel (hence the name
nopaste).
Each pastebin is slightly different. When one pastebin goes down (I'm
looking at you, <http://paste.husk.org>), then you have to find a new one.
And if you usually use a script to publish text, then it's too much
hassle.
This module aims to smooth out the differences between pastebins, and
provides redundancy: if one site doesn't work, it just tries a different
one.
%prep
%setup -q -n "App-Nopaste-%{version}"
%__sed -i '/^auto_install/d' Makefile.PL
%__install -m 0644 "%{SOURCE1}" lib/App/Nopaste/Service/
%build
%__perl Makefile.PL PREFIX="%{_prefix}"
%__make %{?jobs:-j%{jobs}}
%install
%perl_make_install
find "%{buildroot}%{perl_vendorlib}" -type f -name '*.pm' -exec %__chmod 0644 {} \;
%perl_process_packlist
%check
%__make test
%clean
%{?buildroot:%__rm -rf "%{buildroot}"}
%files
%defattr(-,root,root)
%doc Changes
%dir %{perl_vendorlib}/App
%{perl_vendorlib}/App/Nopaste.pm
%dir %{perl_vendorlib}/App/Nopaste
%{perl_vendorlib}/App/Nopaste/*.pm
%dir %{perl_vendorlib}/App/Nopaste/Service
%{perl_vendorlib}/App/Nopaste/Service/*.pm
%dir %{perl_vendorarch}/auto/App
%{perl_vendorarch}/auto/App/Nopaste
%doc %{perl_man3dir}/App::Nopaste.%{perl_man3ext}%{ext_man}
%doc %{perl_man3dir}/App::Nopaste::*.%{perl_man3ext}%{ext_man}
%files -n nopaste
%defattr(-,root,root)
%{_bindir}/nopaste
%doc %{_mandir}/man1/nopaste.1%{ext_man}