Hello community,
here is the log from the commit of package perl-Path-Tiny for openSUSE:Factory checked in at 2016-07-03 12:17:58
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/perl-Path-Tiny (Old)
and /work/SRC/openSUSE:Factory/.perl-Path-Tiny.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "perl-Path-Tiny"
Changes:
--------
--- /work/SRC/openSUSE:Factory/perl-Path-Tiny/perl-Path-Tiny.changes 2016-05-12 09:32:56.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.perl-Path-Tiny.new/perl-Path-Tiny.changes 2016-07-03 12:18:00.000000000 +0200
@@ -1,0 +2,34 @@
+Sat May 28 10:23:26 UTC 2016 - coolo@suse.com
+
+- updated to 0.094
+ see /usr/share/doc/packages/perl-Path-Tiny/Changes
+
+ 0.094 2016-05-23 12:45:19-04:00 America/New_York
+
+ - Fixed Changes note typo in 0.092. 0.092 had no changes since 0.091,
+ not 0.090, meaning that all 0.091 changes were (and are) included.
+
+ 0.092 2016-05-23 11:36:54-04:00 America/New_York
+
+ - No changes from 0.091
+
+ 0.091 2016-05-17 13:32:21-04:00 America/New_York (TRIAL RELEASE)
+
+ [Changes]
+
+ - Path::Tiny will prefer PerlIO::utf8_strict over encoding(UTF-8)
+ if available and Unicode::UTF8 is not installed.
+
+ [Fixes]
+
+ - The 'touch' method can now set the current time on files that aren't
+ owned, as long as they are writeable.
+
+ [Tests]
+
+ - Improved consistency of symlink support inspection; now always
+ looks at $Config{d_symlink}.
+
+ - Skips impossible test on 'msys' platform.
+
+-------------------------------------------------------------------
Old:
----
Path-Tiny-0.090.tar.gz
New:
----
Path-Tiny-0.094.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ perl-Path-Tiny.spec ++++++
--- /var/tmp/diff_new_pack.1Wu57J/_old 2016-07-03 12:18:01.000000000 +0200
+++ /var/tmp/diff_new_pack.1Wu57J/_new 2016-07-03 12:18:01.000000000 +0200
@@ -17,7 +17,7 @@
Name: perl-Path-Tiny
-Version: 0.090
+Version: 0.094
Release: 0
%define cpan_name Path-Tiny
Summary: File path utility
@@ -61,7 +61,9 @@
The '*_utf8' methods ('slurp_utf8', 'lines_utf8', etc.) operate in raw
mode. On Windows, that means they will not have CRLF translation from the
':crlf' IO layer. Installing Unicode::UTF8 0.58 or later will speed up
-'*_utf8' situations in many cases and is highly recommended.
+'*_utf8' situations in many cases and is highly recommended. Alternatively,
+installing PerlIO::utf8_strict 0.003 or later will be used in place of the
+default ':encoding(UTF-8)'.
This module depends heavily on PerlIO layers for correct operation and thus
requires Perl 5.008001 or later.
++++++ Path-Tiny-0.090.tar.gz -> Path-Tiny-0.094.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/Changes new/Path-Tiny-0.094/Changes
--- old/Path-Tiny-0.090/Changes 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/Changes 2016-05-23 18:45:54.000000000 +0200
@@ -1,5 +1,33 @@
Revision history for Path-Tiny
+0.094 2016-05-23 12:45:19-04:00 America/New_York
+
+ - Fixed Changes note typo in 0.092. 0.092 had no changes since 0.091,
+ not 0.090, meaning that all 0.091 changes were (and are) included.
+
+0.092 2016-05-23 11:36:54-04:00 America/New_York
+
+ - No changes from 0.091
+
+0.091 2016-05-17 13:32:21-04:00 America/New_York (TRIAL RELEASE)
+
+ [Changes]
+
+ - Path::Tiny will prefer PerlIO::utf8_strict over encoding(UTF-8)
+ if available and Unicode::UTF8 is not installed.
+
+ [Fixes]
+
+ - The 'touch' method can now set the current time on files that aren't
+ owned, as long as they are writeable.
+
+ [Tests]
+
+ - Improved consistency of symlink support inspection; now always
+ looks at $Config{d_symlink}.
+
+ - Skips impossible test on 'msys' platform.
+
0.090 2016-05-02 07:08:58-04:00 America/New_York
- No changes from 0.089
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/MANIFEST new/Path-Tiny-0.094/MANIFEST
--- old/Path-Tiny-0.090/MANIFEST 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/MANIFEST 2016-05-23 18:45:54.000000000 +0200
@@ -1,4 +1,4 @@
-# This file was automatically generated by Dist::Zilla::Plugin::Manifest v5.047.
+# This file was automatically generated by Dist::Zilla::Plugin::Manifest v6.005.
CONTRIBUTING.mkdn
Changes
LICENSE
@@ -24,6 +24,7 @@
t/exports.t
t/filesystem.t
t/input_output.t
+t/input_output_no_PU_UU.t
t/input_output_no_UU.t
t/lib/TestUtils.pm
t/locking.t
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/META.json new/Path-Tiny-0.094/META.json
--- old/Path-Tiny-0.090/META.json 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/META.json 2016-05-23 18:45:54.000000000 +0200
@@ -4,7 +4,7 @@
"David Golden "
],
"dynamic_config" : 0,
- "generated_by" : "Dist::Zilla version 5.047, CPAN::Meta::Converter version 2.150001",
+ "generated_by" : "Dist::Zilla version 6.005, CPAN::Meta::Converter version 2.150005",
"license" : [
"apache_2_0"
],
@@ -108,11 +108,11 @@
"provides" : {
"Path::Tiny" : {
"file" : "lib/Path/Tiny.pm",
- "version" : "0.090"
+ "version" : "0.094"
},
"Path::Tiny::Error" : {
"file" : "lib/Path/Tiny.pm",
- "version" : "0.090"
+ "version" : "0.094"
}
},
"release_status" : "stable",
@@ -127,7 +127,7 @@
"web" : "https://github.com/dagolden/Path-Tiny"
}
},
- "version" : "0.090",
+ "version" : "0.094",
"x_authority" : "cpan:DAGOLDEN",
"x_contributors" : [
"Alex Efros ",
@@ -141,6 +141,7 @@
"Geraud Continsouzas ",
"Goro Fuji ",
"Graham Knop ",
+ "Graham Ollis ",
"James Hunt ",
"John Karr ",
"Karen Etheridge ",
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/META.yml new/Path-Tiny-0.094/META.yml
--- old/Path-Tiny-0.090/META.yml 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/META.yml 2016-05-23 18:45:54.000000000 +0200
@@ -17,7 +17,7 @@
ExtUtils::MakeMaker: '6.17'
perl: '5.008001'
dynamic_config: 0
-generated_by: 'Dist::Zilla version 5.047, CPAN::Meta::Converter version 2.150001'
+generated_by: 'Dist::Zilla version 6.005, CPAN::Meta::Converter version 2.150005'
license: apache
meta-spec:
url: http://module-build.sourceforge.net/META-spec-v1.4.html
@@ -35,10 +35,10 @@
provides:
Path::Tiny:
file: lib/Path/Tiny.pm
- version: '0.090'
+ version: '0.094'
Path::Tiny::Error:
file: lib/Path/Tiny.pm
- version: '0.090'
+ version: '0.094'
recommends:
Unicode::UTF8: '0.58'
requires:
@@ -64,7 +64,7 @@
bugtracker: https://github.com/dagolden/Path-Tiny/issues
homepage: https://github.com/dagolden/Path-Tiny
repository: https://github.com/dagolden/Path-Tiny.git
-version: '0.090'
+version: '0.094'
x_authority: cpan:DAGOLDEN
x_contributors:
- 'Alex Efros '
@@ -78,6 +78,7 @@
- 'Geraud Continsouzas '
- 'Goro Fuji '
- 'Graham Knop '
+ - 'Graham Ollis '
- 'James Hunt '
- 'John Karr '
- 'Karen Etheridge '
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/Makefile.PL new/Path-Tiny-0.094/Makefile.PL
--- old/Path-Tiny-0.090/Makefile.PL 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/Makefile.PL 2016-05-23 18:45:54.000000000 +0200
@@ -1,4 +1,4 @@
-# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v5.047.
+# This file was automatically generated by Dist::Zilla::Plugin::MakeMaker v6.005.
use strict;
use warnings;
@@ -46,7 +46,7 @@
"lib" => 0,
"open" => 0
},
- "VERSION" => "0.090",
+ "VERSION" => "0.094",
"test" => {
"TESTS" => "t/*.t"
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/README new/Path-Tiny-0.094/README
--- old/Path-Tiny-0.090/README 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/README 2016-05-23 18:45:54.000000000 +0200
@@ -2,7 +2,7 @@
Path::Tiny - File path utility
VERSION
- version 0.090
+ version 0.094
SYNOPSIS
use Path::Tiny;
@@ -65,6 +65,8 @@
mode. On Windows, that means they will not have CRLF translation from
the ":crlf" IO layer. Installing Unicode::UTF8 0.58 or later will speed
up *_utf8 situations in many cases and is highly recommended.
+ Alternatively, installing PerlIO::utf8_strict 0.003 or later will be
+ used in place of the default ":encoding(UTF-8)".
This module depends heavily on PerlIO layers for correct operation and
thus requires Perl 5.008001 or later.
@@ -227,8 +229,9 @@
unbuffered, raw write.
"append_utf8" is like "append" with a "binmode" of
- ":unix:encoding(UTF-8)". If Unicode::UTF8 0.58+ is installed, a raw
- append will be done instead on the data encoded with "Unicode::UTF8".
+ ":unix:encoding(UTF-8)" (or PerlIO::utf8_strict). If Unicode::UTF8 0.58+
+ is installed, a raw append will be done instead on the data encoded with
+ "Unicode::UTF8".
Current API available since 0.060.
@@ -521,11 +524,12 @@
"lines_raw" is like "lines" with a "binmode" of ":raw". We use ":raw"
instead of ":unix" so PerlIO buffering can manage reading by line.
- "lines_utf8" is like "lines" with a "binmode" of ":raw:encoding(UTF-8)".
- If Unicode::UTF8 0.58+ is installed, a raw UTF-8 slurp will be done and
- then the lines will be split. This is actually faster than relying on
- ":encoding(UTF-8)", though a bit memory intensive. If memory use is a
- concern, consider "openr_utf8" and iterating directly on the handle.
+ "lines_utf8" is like "lines" with a "binmode" of ":raw:encoding(UTF-8)"
+ (or PerlIO::utf8_strict). If Unicode::UTF8 0.58+ is installed, a raw
+ UTF-8 slurp will be done and then the lines will be split. This is
+ actually faster than relying on ":encoding(UTF-8)", though a bit memory
+ intensive. If memory use is a concern, consider "openr_utf8" and
+ iterating directly on the handle.
Current API available since 0.065.
@@ -715,8 +719,8 @@
"slurp_raw" is like "slurp" with a "binmode" of ":unix" for a fast,
unbuffered, raw read.
- "slurp_utf8" is like "slurp" with a "binmode" of
- ":unix:encoding(UTF-8)". If Unicode::UTF8 0.58+ is installed, a raw
+ "slurp_utf8" is like "slurp" with a "binmode" of ":unix:encoding(UTF-8)"
+ (or PerlIO::utf8_strict). If Unicode::UTF8 0.58+ is installed, a raw
slurp will be done instead and the result decoded with "Unicode::UTF8".
This is just as strict and is roughly an order of magnitude faster than
using ":encoding(UTF-8)".
@@ -746,9 +750,9 @@
"spew_raw" is like "spew" with a "binmode" of ":unix" for a fast,
unbuffered, raw write.
- "spew_utf8" is like "spew" with a "binmode" of ":unix:encoding(UTF-8)".
- If Unicode::UTF8 0.58+ is installed, a raw spew will be done instead on
- the data encoded with "Unicode::UTF8".
+ "spew_utf8" is like "spew" with a "binmode" of ":unix:encoding(UTF-8)"
+ (or PerlIO::utf8_strict). If Unicode::UTF8 0.58+ is installed, a raw
+ spew will be done instead on the data encoded with "Unicode::UTF8".
NOTE: because the file is written to a temporary file and then renamed,
the new file will wind up with permissions based on your current umask.
@@ -927,7 +931,7 @@
permission, no lock will be used.
utf8 vs UTF-8
- All the *_utf8 methods use ":encoding(UTF-8)" -- either as
+ All the *_utf8 methods by default use ":encoding(UTF-8)" -- either as
":unix:encoding(UTF-8)" (unbuffered) or ":raw:encoding(UTF-8)"
(buffered) -- which is strict against the Unicode spec and disallows
illegal Unicode codepoints or UTF-8 sequences.
@@ -935,7 +939,9 @@
Unfortunately, ":encoding(UTF-8)" is very, very slow. If you install
Unicode::UTF8 0.58 or later, that module will be used by some *_utf8
methods to encode or decode data after a raw, binary input/output
- operation, which is much faster.
+ operation, which is much faster. Alternatively, if you install
+ PerlIO::utf8_strict, that will be used instead of ":encoding(UTF-8)" and
+ is also very fast.
If you need the performance and can accept the security risk,
"slurp({binmode => ":unix:utf8"})" will be faster than
@@ -948,10 +954,6 @@
$path->spew_utf8($data); # raw
$path->spew({binmode => ":encoding(UTF-8)"}, $data; # LF -> CRLF
- Consider PerlIO::utf8_strict for a faster PerlIO layer alternative to
- ":encoding(UTF-8)", though it does not appear to be as fast as the
- "Unicode::UTF8" approach.
-
Default IO layers and the open pragma
If you have Perl 5.10 or later, file input/output methods ("slurp",
"spew", etc.) and high-level handle opening methods ( "filehandle",
@@ -1030,6 +1032,8 @@
* Graham Knop
+ * Graham Ollis
+
* James Hunt
* John Karr
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/dist.ini new/Path-Tiny-0.094/dist.ini
--- old/Path-Tiny-0.090/dist.ini 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/dist.ini 2016-05-23 18:45:54.000000000 +0200
@@ -36,6 +36,7 @@
[RemovePrereqs]
remove = Unicode::UTF8
+remove = PerlIO::utf8_strict
remove = Path::Class
remove = Test::FailWarnings
remove = threads
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/lib/Path/Tiny.pm new/Path-Tiny-0.094/lib/Path/Tiny.pm
--- old/Path-Tiny-0.090/lib/Path/Tiny.pm 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/lib/Path/Tiny.pm 2016-05-23 18:45:54.000000000 +0200
@@ -5,7 +5,7 @@
package Path::Tiny;
# ABSTRACT: File path utility
-our $VERSION = '0.090';
+our $VERSION = '0.094';
# Dependencies
use Config;
@@ -44,6 +44,12 @@
!!eval { require Unicode::UTF8; Unicode::UTF8->VERSION(0.58); 1 };
}
+my $HAS_PU; # has PerlIO::utf8_strict; lazily populated
+
+sub _check_PU {
+ !!eval { require PerlIO::utf8_strict; PerlIO::utf8_strict->VERSION(0.003); 1 };
+}
+
my $HAS_FLOCK = $Config{d_flock} || $Config{d_fcntl_can_lock} || $Config{d_lockf};
# notions of "root" directories differ on Win32: \\server\dir\ or C:\ or \
@@ -488,8 +494,9 @@
#pod unbuffered, raw write.
#pod
#pod C is like C<append> with a C<binmode> of
-#pod C<:unix:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
-#pod append will be done instead on the data encoded with CUnicode::UTF8.
+#pod C<:unix:encoding(UTF-8)> (or LPerlIO::utf8_strict). If LUnicode::UTF8
+#pod 0.58+ is installed, a raw append will be done instead on the data encoded
+#pod with CUnicode::UTF8.
#pod
#pod Current API available since 0.060.
#pod
@@ -523,6 +530,10 @@
$args->{binmode} = ":unix";
append( $self, $args, map { Unicode::UTF8::encode_utf8($_) } @data );
}
+ elsif ( defined($HAS_PU) ? $HAS_PU : ( $HAS_PU = _check_PU() ) ) {
+ $args->{binmode} = ":unix:utf8_strict";
+ append( $self, $args, @data );
+ }
else {
$args->{binmode} = ":unix:encoding(UTF-8)";
append( $self, $args, @data );
@@ -1170,8 +1181,8 @@
#pod C is like C<lines> with a C<binmode> of C<:raw>. We use C<:raw>
#pod instead of C<:unix> so PerlIO buffering can manage reading by line.
#pod
-#pod C is like C<lines> with a C<binmode> of
-#pod C<:raw:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
+#pod C is like C<lines> with a C<binmode> of C<:raw:encoding(UTF-8)>
+#pod (or LPerlIO::utf8_strict). If LUnicode::UTF8 0.58+ is installed, a raw
#pod UTF-8 slurp will be done and then the lines will be split. This is
#pod actually faster than relying on C<:encoding(UTF-8)>, though a bit memory
#pod intensive. If memory use is a concern, consider C and
@@ -1237,6 +1248,10 @@
$slurp =~ s/$CRLF$//; # like chomp, but full CR?LF|CR
return split $CRLF, $slurp, -1; ## no critic
}
+ elsif ( defined($HAS_PU) ? $HAS_PU : ( $HAS_PU = _check_PU() ) ) {
+ $args->{binmode} = ":unix:utf8_strict";
+ return lines( $self, $args );
+ }
else {
$args->{binmode} = ":raw:encoding(UTF-8)";
return lines( $self, $args );
@@ -1689,10 +1704,10 @@
#pod a fast, unbuffered, raw read.
#pod
#pod C is like C<slurp> with a C<binmode> of
-#pod C<:unix:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
-#pod slurp will be done instead and the result decoded with CUnicode::UTF8.
-#pod This is just as strict and is roughly an order of magnitude faster than
-#pod using C<:encoding(UTF-8)>.
+#pod C<:unix:encoding(UTF-8)> (or LPerlIO::utf8_strict). If LUnicode::UTF8
+#pod 0.58+ is installed, a raw slurp will be done instead and the result decoded
+#pod with CUnicode::UTF8. This is just as strict and is roughly an order of
+#pod magnitude faster than using C<:encoding(UTF-8)>.
#pod
#pod B<Note>: C<slurp> and friends lock the filehandle before slurping. If
#pod you plan to slurp from a file created with LFile::Temp, be sure to
@@ -1730,6 +1745,10 @@
if ( defined($HAS_UU) ? $HAS_UU : ( $HAS_UU = _check_UU() ) ) {
return Unicode::UTF8::decode_utf8( slurp( $_[0], { binmode => ":unix" } ) );
}
+ elsif ( defined($HAS_PU) ? $HAS_PU : ( $HAS_PU = _check_PU() ) ) {
+ $_[1] = { binmode => ":unix:utf8_strict" };
+ goto &slurp;
+ }
else {
$_[1] = { binmode => ":raw:encoding(UTF-8)" };
goto &slurp;
@@ -1752,9 +1771,9 @@
#pod C is like C<spew> with a C<binmode> of C<:unix> for a fast,
#pod unbuffered, raw write.
#pod
-#pod C is like C<spew> with a C<binmode> of C<:unix:encoding(UTF-8)>.
-#pod If LUnicode::UTF8 0.58+ is installed, a raw spew will be done instead on
-#pod the data encoded with CUnicode::UTF8.
+#pod C is like C<spew> with a C<binmode> of C<:unix:encoding(UTF-8)>
+#pod (or LPerlIO::utf8_strict). If LUnicode::UTF8 0.58+ is installed, a raw
+#pod spew will be done instead on the data encoded with CUnicode::UTF8.
#pod
#pod B<NOTE>: because the file is written to a temporary file and then renamed, the
#pod new file will wind up with permissions based on your current umask. This is a
@@ -1798,6 +1817,10 @@
map { Unicode::UTF8::encode_utf8($_) } map { ref eq 'ARRAY' ? @$_ : $_ } @_
);
}
+ elsif ( defined($HAS_PU) ? $HAS_PU : ( $HAS_PU = _check_PU() ) ) {
+ splice @_, 1, 0, { binmode => ":unix:utf8_strict" };
+ goto &spew;
+ }
else {
splice @_, 1, 0, { binmode => ":unix:encoding(UTF-8)" };
goto &spew;
@@ -1925,9 +1948,15 @@
my $fh = $self->openw;
close $fh or $self->_throw('close');
}
- $epoch = defined($epoch) ? $epoch : time();
- utime $epoch, $epoch, $self->[PATH]
- or $self->_throw("utime ($epoch)");
+ if ( defined $epoch ) {
+ utime $epoch, $epoch, $self->[PATH]
+ or $self->_throw("utime ($epoch)");
+ }
+ else {
+ # literal undef prevents warnings :-(
+ utime undef, undef, $self->[PATH]
+ or $self->_throw("utime ()");
+ }
return $self;
}
@@ -2065,7 +2094,7 @@
=head1 VERSION
-version 0.090
+version 0.094
=head1 SYNOPSIS
@@ -2126,10 +2155,12 @@
File input/output methods C<flock> handles before reading or writing,
as appropriate (if supported by the platform).
-The C<*_utf8> methods (C, C, etc.) operate in raw mode.
-On Windows, that means they will not have CRLF translation from the C<:crlf> IO
-layer. Installing LUnicode::UTF8 0.58 or later will speed up C<*_utf8>
-situations in many cases and is highly recommended.
+The C<*_utf8> methods (C, C, etc.) operate in raw
+mode. On Windows, that means they will not have CRLF translation from the
+C<:crlf> IO layer. Installing LUnicode::UTF8 0.58 or later will speed up
+C<*_utf8> situations in many cases and is highly recommended.
+Alternatively, installing LPerlIO::utf8_strict 0.003 or later will be
+used in place of the default C<:encoding(UTF-8)>.
This module depends heavily on PerlIO layers for correct operation and thus
requires Perl 5.008001 or later.
@@ -2307,8 +2338,9 @@
unbuffered, raw write.
C is like C<append> with a C<binmode> of
-C<:unix:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
-append will be done instead on the data encoded with CUnicode::UTF8.
+C<:unix:encoding(UTF-8)> (or LPerlIO::utf8_strict). If LUnicode::UTF8
+0.58+ is installed, a raw append will be done instead on the data encoded
+with CUnicode::UTF8.
Current API available since 0.060.
@@ -2613,8 +2645,8 @@
C is like C<lines> with a C<binmode> of C<:raw>. We use C<:raw>
instead of C<:unix> so PerlIO buffering can manage reading by line.
-C is like C<lines> with a C<binmode> of
-C<:raw:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
+C is like C<lines> with a C<binmode> of C<:raw:encoding(UTF-8)>
+(or LPerlIO::utf8_strict). If LUnicode::UTF8 0.58+ is installed, a raw
UTF-8 slurp will be done and then the lines will be split. This is
actually faster than relying on C<:encoding(UTF-8)>, though a bit memory
intensive. If memory use is a concern, consider C and
@@ -2829,10 +2861,10 @@
a fast, unbuffered, raw read.
C is like C<slurp> with a C<binmode> of
-C<:unix:encoding(UTF-8)>. If LUnicode::UTF8 0.58+ is installed, a raw
-slurp will be done instead and the result decoded with CUnicode::UTF8.
-This is just as strict and is roughly an order of magnitude faster than
-using C<:encoding(UTF-8)>.
+C<:unix:encoding(UTF-8)> (or LPerlIO::utf8_strict). If LUnicode::UTF8
+0.58+ is installed, a raw slurp will be done instead and the result decoded
+with CUnicode::UTF8. This is just as strict and is roughly an order of
+magnitude faster than using C<:encoding(UTF-8)>.
B<Note>: C<slurp> and friends lock the filehandle before slurping. If
you plan to slurp from a file created with LFile::Temp, be sure to
@@ -2859,9 +2891,9 @@
C is like C<spew> with a C<binmode> of C<:unix> for a fast,
unbuffered, raw write.
-C is like C<spew> with a C<binmode> of C<:unix:encoding(UTF-8)>.
-If LUnicode::UTF8 0.58+ is installed, a raw spew will be done instead on
-the data encoded with CUnicode::UTF8.
+C is like C<spew> with a C<binmode> of C<:unix:encoding(UTF-8)>
+(or LPerlIO::utf8_strict). If LUnicode::UTF8 0.58+ is installed, a raw
+spew will be done instead on the data encoded with CUnicode::UTF8.
B<NOTE>: because the file is written to a temporary file and then renamed, the
new file will wind up with permissions based on your current umask. This is a
@@ -3064,7 +3096,7 @@
=head2 utf8 vs UTF-8
-All the C<*_utf8> methods use C<:encoding(UTF-8)> -- either as
+All the C<*_utf8> methods by default use C<:encoding(UTF-8)> -- either as
C<:unix:encoding(UTF-8)> (unbuffered) or C<:raw:encoding(UTF-8)> (buffered) --
which is strict against the Unicode spec and disallows illegal Unicode
codepoints or UTF-8 sequences.
@@ -3072,7 +3104,8 @@
Unfortunately, C<:encoding(UTF-8)> is very, very slow. If you install
LUnicode::UTF8 0.58 or later, that module will be used by some C<*_utf8>
methods to encode or decode data after a raw, binary input/output operation,
-which is much faster.
+which is much faster. Alternatively, if you install LPerlIO::utf8_strict,
+that will be used instead of C<:encoding(UTF-8)> and is also very fast.
If you need the performance and can accept the security risk,
C<< slurp({binmode => ":unix:utf8"}) >> will be faster than C<:unix:encoding(UTF-8)>
@@ -3085,10 +3118,6 @@
$path->spew_utf8($data); # raw
$path->spew({binmode => ":encoding(UTF-8)"}, $data; # LF -> CRLF
-Consider LPerlIO::utf8_strict for a faster L<PerlIO> layer alternative to
-C<:encoding(UTF-8)>, though it does not appear to be as fast as the
-CUnicode::UTF8 approach.
-
=head2 Default IO layers and the open pragma
If you have Perl 5.10 or later, file input/output methods (C<slurp>, C<spew>,
@@ -3173,7 +3202,7 @@
=head1 CONTRIBUTORS
-=for stopwords Alex Efros Chris Williams David Golden Steinbrunner Doug Bell Gabor Szabo Gabriel Andrade George Hartzell Geraud Continsouzas Goro Fuji Graham Knop James Hunt John Karr Karen Etheridge Mark Ellis Martin Kjeldsen Michael G. Schwern Nigel Gregoire Philippe Bruhat (BooK) Regina Verbae Roy Ivy III Shlomi Fish Smylers Tatsuhiko Miyagawa Toby Inkster Yanick Champoux 김도형 - Keedi Kim
+=for stopwords Alex Efros Chris Williams David Golden Steinbrunner Doug Bell Gabor Szabo Gabriel Andrade George Hartzell Geraud Continsouzas Goro Fuji Graham Knop Ollis James Hunt John Karr Karen Etheridge Mark Ellis Martin Kjeldsen Michael G. Schwern Nigel Gregoire Philippe Bruhat (BooK) Regina Verbae Roy Ivy III Shlomi Fish Smylers Tatsuhiko Miyagawa Toby Inkster Yanick Champoux 김도형 - Keedi Kim
=over 4
@@ -3223,6 +3252,10 @@
=item *
+Graham Ollis
+
+=item *
+
James Hunt
=item *
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/t/filesystem.t new/Path-Tiny-0.094/t/filesystem.t
--- old/Path-Tiny-0.090/t/filesystem.t 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/t/filesystem.t 2016-05-23 18:45:54.000000000 +0200
@@ -4,6 +4,7 @@
use Test::More 0.96;
use File::Temp qw(tmpnam tempdir);
use File::Spec;
+use Config;
use Cwd;
use lib 't/lib';
@@ -344,7 +345,7 @@
my $link = $newtmp->child("bar.txt");
$file->spew("Hello World\n");
eval { symlink $file => $link };
- skip "symlink unavailable", 1 if $@;
+ skip "symlink unavailable", 1 unless $Config{d_symlink};
ok( $link->lstat->size, "lstat" );
is( $link->realpath, $file->realpath, "realpath resolves symlinks" );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/t/input_output_no_PU_UU.t new/Path-Tiny-0.094/t/input_output_no_PU_UU.t
--- old/Path-Tiny-0.090/t/input_output_no_PU_UU.t 1970-01-01 01:00:00.000000000 +0100
+++ new/Path-Tiny-0.094/t/input_output_no_PU_UU.t 2016-05-23 18:45:54.000000000 +0200
@@ -0,0 +1,24 @@
+use 5.008001;
+use strict;
+use warnings;
+use Test::More 0.96;
+
+# Tiny equivalent of Devel::Hide
+BEGIN {
+ $INC{'Unicode/UTF8.pm'} = undef;
+ $INC{'PerlIO/utf8_strict.pm'} = undef;
+}
+
+note "Hiding Unicode::UTF8 and PerlIO::utf8_strict";
+
+do "t/input_output.t";
+
+#
+# This file is part of Path-Tiny
+#
+# This software is Copyright (c) 2014 by David Golden.
+#
+# This is free software, licensed under:
+#
+# The Apache License, Version 2.0, January 2004
+#
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/t/mkpath.t new/Path-Tiny-0.094/t/mkpath.t
--- old/Path-Tiny-0.090/t/mkpath.t 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/t/mkpath.t 2016-05-23 18:45:54.000000000 +0200
@@ -21,7 +21,9 @@
my $path2 = path($tempdir)->child("bar");
ok( !-e $path2, "target directory not created yet" );
ok( $path2->mkpath( { mode => 0700 } ), "mkpath on directory with mode" );
- is( $path2->stat->mode & 0777, 0700, "correct mode" );
+ if ( $^O ne 'msys' ) {
+ is( $path2->stat->mode & 0777, 0700, "correct mode" );
+ }
ok( -d $path2, "target directory created" );
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/t/rel-abs.t new/Path-Tiny-0.094/t/rel-abs.t
--- old/Path-Tiny-0.090/t/rel-abs.t 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/t/rel-abs.t 2016-05-23 18:45:54.000000000 +0200
@@ -2,6 +2,7 @@
use strict;
use warnings;
use Test::More 0.96;
+use Config;
use lib 't/lib';
use TestUtils qw/exception pushd tempd/;
@@ -109,9 +110,8 @@
my $deep = $cwd->child("foo/bar/baz/bam/bim/buz/wiz/was/woz");
$deep->mkpath();
- eval { symlink "foo/bar/baz", "baz" };
plan skip_all => "No symlink support"
- if $@;
+ unless $Config{d_symlink};
my ( $path, $base, $expect );
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/xt/author/pod-spell.t new/Path-Tiny-0.094/xt/author/pod-spell.t
--- old/Path-Tiny-0.090/xt/author/pod-spell.t 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/xt/author/pod-spell.t 2016-05-23 18:45:54.000000000 +0200
@@ -66,6 +66,8 @@
Graham
Knop
haarg
+Ollis
+plicease
James
Hunt
james
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/Path-Tiny-0.090/xt/author/test-version.t new/Path-Tiny-0.094/xt/author/test-version.t
--- old/Path-Tiny-0.090/xt/author/test-version.t 2016-05-02 13:09:21.000000000 +0200
+++ new/Path-Tiny-0.094/xt/author/test-version.t 2016-05-23 18:45:54.000000000 +0200
@@ -2,7 +2,7 @@
use warnings;
use Test::More;
-# generated by Dist::Zilla::Plugin::Test::Version 1.06
+# generated by Dist::Zilla::Plugin::Test::Version 1.09
use Test::Version;
my @imports = qw( version_all_ok );