2011-04-04 10:31:53 +02:00
|
|
|
#
|
2011-07-19 16:21:33 +02:00
|
|
|
# spec file for package perl-YAML-Tiny
|
2011-04-04 10:31:53 +02:00
|
|
|
#
|
2023-04-03 15:21:31 +02:00
|
|
|
# Copyright (c) 2023 SUSE LLC
|
2011-04-04 10:31:53 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
2023-04-03 15:21:31 +02:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2011-04-04 10:31:53 +02:00
|
|
|
#
|
2010-08-26 13:27:17 +02:00
|
|
|
|
2011-07-19 16:21:33 +02:00
|
|
|
|
2023-04-03 15:21:31 +02:00
|
|
|
%define cpan_name YAML-Tiny
|
2010-08-26 13:27:17 +02:00
|
|
|
Name: perl-YAML-Tiny
|
2023-04-03 15:21:31 +02:00
|
|
|
Version: 1.74
|
2012-05-23 15:02:39 +02:00
|
|
|
Release: 0
|
2018-02-24 08:03:13 +01:00
|
|
|
License: Artistic-1.0 OR GPL-1.0-or-later
|
2023-04-03 15:21:31 +02:00
|
|
|
Summary: Read/Write YAML files with as little code as possible
|
|
|
|
URL: https://metacpan.org/release/%{cpan_name}
|
2017-02-14 10:07:08 +01:00
|
|
|
Source0: https://cpan.metacpan.org/authors/id/E/ET/ETHER/%{cpan_name}-%{version}.tar.gz
|
2015-05-13 16:56:37 +02:00
|
|
|
Source1: cpanspec.yml
|
2011-04-04 10:31:53 +02:00
|
|
|
BuildArch: noarch
|
|
|
|
BuildRequires: perl
|
2010-12-03 15:57:06 +01:00
|
|
|
BuildRequires: perl-macros
|
2015-05-13 16:56:37 +02:00
|
|
|
BuildRequires: perl(File::Temp) >= 0.19
|
|
|
|
BuildRequires: perl(JSON::PP)
|
2015-07-29 11:14:00 +02:00
|
|
|
BuildRequires: perl(Test::More) >= 0.88
|
2011-04-04 10:31:53 +02:00
|
|
|
%{perl_requires}
|
2010-08-26 13:27:17 +02:00
|
|
|
|
|
|
|
%description
|
2011-04-04 10:31:53 +02:00
|
|
|
*YAML::Tiny* is a perl class for reading and writing YAML-style files,
|
|
|
|
written with as little code as possible, reducing load time and memory
|
|
|
|
overhead.
|
|
|
|
|
|
|
|
Most of the time it is accepted that Perl applications use a lot of memory
|
|
|
|
and modules. The *::Tiny* family of modules is specifically intended to
|
|
|
|
provide an ultralight and zero-dependency alternative to many more-thorough
|
|
|
|
standard modules.
|
|
|
|
|
|
|
|
This module is primarily for reading human-written files (like simple
|
|
|
|
config files) and generating very simple human-readable files. Note that I
|
|
|
|
said *human-readable* and not *geek-readable*. The sort of files that your
|
|
|
|
average manager or secretary should be able to look at and make sense of.
|
|
|
|
|
2017-02-14 10:07:08 +01:00
|
|
|
YAML::Tiny does not generate comments, it won't necessarily preserve the
|
|
|
|
order of your hashes, and it will normalise if reading in and writing out
|
|
|
|
again.
|
2011-04-04 10:31:53 +02:00
|
|
|
|
|
|
|
It only supports a very basic subset of the full YAML specification.
|
2010-08-26 13:27:17 +02:00
|
|
|
|
2013-10-04 17:24:20 +02:00
|
|
|
Usage is targeted at files like Perl's META.yml, for which a small and
|
2011-04-04 10:31:53 +02:00
|
|
|
easily-embeddable module is extremely attractive.
|
2010-08-26 13:27:17 +02:00
|
|
|
|
2011-04-04 10:31:53 +02:00
|
|
|
Features will only be added if they are human readable, and can be written
|
|
|
|
in a few lines of code. Please don't be offended if your request is
|
|
|
|
refused. Someone has to draw the line, and for YAML::Tiny that someone is
|
|
|
|
me.
|
|
|
|
|
2017-02-14 10:07:08 +01:00
|
|
|
If you need something with more power move up to YAML (7 megabytes of
|
|
|
|
memory overhead) or YAML::XS (6 megabytes memory overhead and requires a C
|
|
|
|
compiler).
|
2011-04-04 10:31:53 +02:00
|
|
|
|
2017-02-14 10:07:08 +01:00
|
|
|
To restate, YAML::Tiny does *not* preserve your comments, whitespace, or
|
|
|
|
the order of your YAML data. But it should round-trip from Perl structure
|
|
|
|
to file and back again just fine.
|
2010-08-26 13:27:17 +02:00
|
|
|
|
|
|
|
%prep
|
2023-04-03 15:21:31 +02:00
|
|
|
%autosetup -n %{cpan_name}-%{version}
|
|
|
|
|
|
|
|
find . -type f ! -path "*/t/*" ! -name "*.pl" ! -path "*/bin/*" ! -path "*/script/*" ! -name "configure" -print0 | xargs -0 chmod 644
|
2010-08-26 13:27:17 +02:00
|
|
|
|
|
|
|
%build
|
2023-04-03 15:21:31 +02:00
|
|
|
perl Makefile.PL INSTALLDIRS=vendor
|
|
|
|
%make_build
|
2011-04-04 10:31:53 +02:00
|
|
|
|
|
|
|
%check
|
2023-04-03 15:21:31 +02:00
|
|
|
make test
|
2011-04-04 10:31:53 +02:00
|
|
|
|
2010-08-26 13:27:17 +02:00
|
|
|
%install
|
2015-04-15 07:07:22 +02:00
|
|
|
%perl_make_install
|
|
|
|
%perl_process_packlist
|
2011-04-04 10:31:53 +02:00
|
|
|
%perl_gen_filelist
|
2010-08-26 13:27:17 +02:00
|
|
|
|
2011-04-04 10:31:53 +02:00
|
|
|
%files -f %{name}.files
|
2017-02-14 10:07:08 +01:00
|
|
|
%doc Changes CONTRIBUTING README
|
|
|
|
%license LICENSE
|
2010-08-26 13:27:17 +02:00
|
|
|
|
2011-04-04 10:31:53 +02:00
|
|
|
%changelog
|