Hello community, here is the log from the commit of package xls2csv for openSUSE:Factory checked in at 2014-09-09 19:00:03 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/xls2csv (Old) and /work/SRC/openSUSE:Factory/.xls2csv.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Package is "xls2csv" Changes: -------- --- /work/SRC/openSUSE:Factory/xls2csv/xls2csv.changes 2013-03-01 21:03:23.000000000 +0100 +++ /work/SRC/openSUSE:Factory/.xls2csv.new/xls2csv.changes 2014-09-09 19:00:20.000000000 +0200 @@ -1,0 +2,11 @@ +Mon Sep 8 18:17:30 UTC 2014 - adam@mizerski.pl + +- updated to 1.07 + - BUG#64000 - 0 is no longer treated as "empty" + - BUG#33248 - Added the -f option, which will force rows to be + parsed even if the first column is blank. + - Added the -n option, which lets you specify the worksheet you + want to convert by its number. +- cleaned up spec file + +------------------------------------------------------------------- Old: ---- xls2csv-1.06.tar.bz2 New: ---- xls2csv-1.07.tar.bz2 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ xls2csv.spec ++++++ --- /var/tmp/diff_new_pack.MBCSxm/_old 2014-09-09 19:00:21.000000000 +0200 +++ /var/tmp/diff_new_pack.MBCSxm/_new 2014-09-09 19:00:21.000000000 +0200 @@ -1,7 +1,7 @@ # # spec file for package xls2csv # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -17,16 +17,14 @@ Name: xls2csv -Version: 1.06 +Version: 1.07 Release: 0 Summary: A script that recodes a spreadsheet's charset and saves as CSV License: Artistic-1.0 or GPL-2.0+ Group: Productivity/Text/Convertors - -Url: http://search.cpan.org/~ken/xls2csv-1.06/script/xls2csv +Url: http://search.cpan.org/~ken/xls2csv/script/xls2csv # repacked http://search.cpan.org/CPAN/authors/id/K/KE/KEN/%%{name}-%%{version}.tar.gz Source0: %{name}-%{version}.tar.bz2 - BuildRequires: perl BuildRequires: perl(ExtUtils::MakeMaker) BuildRequires: perl(Module::Build) @@ -46,20 +44,17 @@ %setup -q %build -%{__perl} Makefile.PL -%{__make} %{?_smp_mflags} OPTIMIZE="%{optflags}" +perl Makefile.PL +make %{?_smp_mflags} OPTIMIZE="%{optflags}" %install -%{__make} pure_install DESTDIR=%{buildroot} +make pure_install DESTDIR=%{buildroot} find %{buildroot} -name .packlist -print -delete -%clean -%{__rm} -rf %{buildroot} - %files %defattr(-, root, root) %{_bindir}/xls2csv %doc %{_mandir}/man1/xls2csv.1* -%doc README +%doc Changes README %changelog ++++++ xls2csv-1.06.tar.bz2 -> xls2csv-1.07.tar.bz2 ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xls2csv-1.06/Changes new/xls2csv-1.07/Changes --- old/xls2csv-1.06/Changes 2005-09-30 20:57:59.000000000 +0200 +++ new/xls2csv-1.07/Changes 2012-01-22 07:01:56.000000000 +0100 @@ -1,5 +1,10 @@ Revision history for Perl script xls2csv. +1.07 Jan 21, 2012 + - BUG#64000 - 0 is no longer treated as "empty" + - BUG#33248 - Added the -f option, which will force rows to be parsed even if the first column is blank. + - Added the -n option, which lets you specify the worksheet you want to convert by its number. + 1.06 Fri Sep 30 - Now works with multiple worksheets. The worksheet name may be specified with -w. Can also now get a list of all the worksheets in a spreadsheet with the -W switch. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xls2csv-1.06/MANIFEST new/xls2csv-1.07/MANIFEST --- old/xls2csv-1.06/MANIFEST 2005-09-23 22:41:59.000000000 +0200 +++ new/xls2csv-1.07/MANIFEST 2012-01-22 07:10:49.000000000 +0100 @@ -1,7 +1,7 @@ Changes Makefile.PL -MANIFEST +MANIFEST This list of files README -t/xls2csv.t script/xls2csv +t/xls2csv.t META.yml Module meta-data (added by MakeMaker) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xls2csv-1.06/META.yml new/xls2csv-1.07/META.yml --- old/xls2csv-1.06/META.yml 2005-09-30 20:59:22.000000000 +0200 +++ new/xls2csv-1.07/META.yml 2012-01-22 07:10:49.000000000 +0100 @@ -1,15 +1,26 @@ -# http://module-build.sourceforge.net/META-spec.html -#XXXXXXX This is a prototype!!! It will change in the future!!! XXXXX# -name: xls2csv -version: 1.06 -version_from: script/xls2csv -installdirs: site +--- #YAML:1.0 +name: xls2csv +version: 1.07 +abstract: A script that recodes a spreadsheet's charset and saves as CSV. +author: + - Ken Prows <perl@xev.net> +license: unknown +distribution_type: module +configure_requires: + ExtUtils::MakeMaker: 0 +build_requires: + ExtUtils::MakeMaker: 0 requires: - Locale::Recode: 0 - Spreadsheet::ParseExcel: 0 - Spreadsheet::ParseExcel::FmtUnicode: 0 - Text::CSV_XS: 0 - Unicode::Map: 0 - -distribution_type: module -generated_by: ExtUtils::MakeMaker version 6.17 + Locale::Recode: 0 + Spreadsheet::ParseExcel: 0 + Spreadsheet::ParseExcel::FmtUnicode: 0 + Text::CSV_XS: 0 + Unicode::Map: 0 +no_index: + directory: + - t + - inc +generated_by: ExtUtils::MakeMaker version 6.56 +meta-spec: + url: http://module-build.sourceforge.net/META-spec-v1.4.html + version: 1.4 diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xls2csv-1.06/README new/xls2csv-1.07/README --- old/xls2csv-1.06/README 2005-09-30 20:55:14.000000000 +0200 +++ new/xls2csv-1.07/README 2012-01-22 07:08:52.000000000 +0100 @@ -1,5 +1,5 @@ -xls2csv version 1.06 -==================== +xls2csv +======= This will install the xls2csv script. @@ -19,7 +19,7 @@ COPYRIGHT AND LICENCE -Copyright (C) 2005 Ken Prows. (perl@xev.net) +Copyright (C) 2005-2012 Ken Prows. (perl@xev.net) All rights reserved. This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/xls2csv-1.06/script/xls2csv new/xls2csv-1.07/script/xls2csv --- old/xls2csv-1.06/script/xls2csv 2005-09-30 20:55:27.000000000 +0200 +++ new/xls2csv-1.07/script/xls2csv 2012-01-22 07:09:48.000000000 +0100 @@ -8,7 +8,7 @@ use Spreadsheet::ParseExcel::FmtUnicode; use Text::CSV_XS; -our $VERSION = '1.06'; +our $VERSION = '1.07'; =head1 NAME @@ -34,6 +34,8 @@ -v : get version information -W : list worksheets in the spreadsheet specified by -x -w : specify the worksheet name to convert (defaults to the first worksheet) + -n : specify the worksheet number to convert (you cannot use this option with -w) + -f : force the worsheet to be fully parsed. This disables the feature that skips rows when the first cell is blank =head1 EXAMPLE USAGE @@ -76,7 +78,7 @@ $Getopt::Std::STANDARD_HELP_VERSION = 1; my %O; -getopts('x:b:c:a:qshvWw:', \%O); +getopts('x:b:c:a:qshvWw:n:f', \%O); HELP_MESSAGE() if !%O or $O{'h'}; VERSION_MESSAGE() if $O{'v'}; @@ -92,7 +94,7 @@ exit; } -my $SourceFilename = $O{'x'} || die "The filename of the spreadsheet (-x) is required."; +my $SourceFilename = $O{'x'} || die "The filename of the spreadsheet (-x) is required.\n"; my $SourceCharset = $O{'b'}; $SourceCharset = 'UTF-8' unless $SourceCharset; @@ -102,9 +104,9 @@ } my $XLS = new IO::File; -$XLS->open("< $SourceFilename") || die "Cannot open spreadsheet: $!"; +$XLS->open("< $SourceFilename") || die "Cannot open spreadsheet: $!\n"; my $Formatter = Spreadsheet::ParseExcel::FmtUnicode->new(Unicode_Map => $SourceCharset); -my $Book = Spreadsheet::ParseExcel::Workbook->Parse($XLS, $Formatter) || die "Can't read spreadsheet!"; +my $Book = Spreadsheet::ParseExcel::Workbook->Parse($XLS, $Formatter) || die "Can't read spreadsheet!\n"; if ($O{'W'}) { @@ -117,7 +119,7 @@ exit; } -my $DestFilename = $O{'c'} || die "The filename to save the csv file as (-c) is required."; +my $DestFilename = $O{'c'} || die "The filename to save the csv file as (-c) is required.\n"; my $DestCharset = $O{'a'}; $DestCharset = $SourceCharset unless $DestCharset; @@ -125,12 +127,18 @@ if ($O{'w'}) { $Sheet = $Book->Worksheet($O{'w'}); - die "Invalid worksheet" if !defined $Sheet; + die "Invalid worksheet\n" if !defined $Sheet; unless ($O{'q'}) { print qq|Converting the "$Sheet->{Name}" worksheet.\n|; } } +elsif ($O{'n'}) +{ + my $sheet_number = $O{'n'} - 1; + $Sheet = $Book->{Worksheet}->[$sheet_number]; + die "Invalid worksheet\n" if !defined $Sheet; +} else { ($Sheet) = @{$Book->{Worksheet}}; @@ -140,7 +148,7 @@ } } -open CSV, "> $DestFilename" || die "Cannot create csv file: $!" ; +open CSV, "> $DestFilename" || die "Cannot create csv file: $!\n" ; binmode CSV; my $Csv = Text::CSV_XS->new({ 'quote_char' => '"', @@ -178,8 +186,14 @@ } } - # We assume the line is blank if there is nothing in the first column. - last if $Col == $Sheet->{MinCol} and !$Value; + unless ($O{'f'}) + { + # We assume the line is blank if there is nothing in the first column. + if ( $Col == $Sheet->{MinCol} and ( !defined($Value) || $Value eq q{} ) ) + { + last; + } + } push(@Row, $Value); } @@ -215,7 +229,7 @@ This is xls2csv version $VERSION -Copyright (C) 2005 Ken Prows. All rights reserved. +Copyright (C) 2005-2012 Ken Prows. All rights reserved. This script is free software; you can redistribute it and\\or modify it under the same terms as Perl itself. @@ -231,7 +245,7 @@ xls2csv - Recode a spreadsheet's charset and save as CSV. -usage: xls2csv -x spreadsheet.xls [-w worksheet] [-b charset] [-c csvfile.csv] [-a charset] [-qshvW] +usage: xls2csv -x spreadsheet.xls [-w worksheet] [-n worksheet number] [-b charset] [-c csvfile.csv] [-a charset] [-qshvWf] -x : filename of the source spreadsheet -b : the character set the source spreadsheet is in (before) @@ -243,6 +257,8 @@ -v : get version information -W : list worksheets in the spreadsheet specified by -x -w : specify the worksheet name to convert (defaults to the first worksheet) +-n : specify the worksheet number to convert (you cannot use this option with -w) +-f : force the worsheet to be fully parsed. This disables the feature that skips rows when the first cell is blank example: xls2csv -x "spreadsheet.xls" -b WINDOWS-1252 -c "csvfile.csv" -a UTF-8 @@ -258,7 +274,7 @@ =head1 COPYRIGHT -Copyright (C) 2005 Ken Prows. All rights reserved. +Copyright (C) 2005-2012 Ken Prows. All rights reserved. This script is free software; you can redistribute it and/or modify it under the same terms as Perl itself. -- To unsubscribe, e-mail: opensuse-commit+unsubscribe@opensuse.org For additional commands, e-mail: opensuse-commit+help@opensuse.org