Skip to content

Commit

Permalink
Checking in changes prior to tagging of version 2.01.
Browse files Browse the repository at this point in the history
Changelog diff is:

diff --git a/Changes b/Changes
index 68d5102..f48b1ac 100644
--- a/Changes
+++ b/Changes
@@ -2,6 +2,9 @@ Revision history for Perl extension HTML::Shakan

 {{$NEXT}}

+2.01 2015-07-20T15:40:39Z
+    - Introduce Model::Teng (GeJ++)
+
 2.00 2013-11-20T07:22:24Z
     - Bump up major version

@@ -18,7 +21,7 @@ Revision history for Perl extension HTML::Shakan
     - Use HTML::Escape while escaping HTML chars.
       It makes HTML::Shakan faster.

-      You need to care while updating this module.
+      You need to care while updating this module.
       HTML::Escape escapes more characters by default.
       (Masayuki Matsuki)
  • Loading branch information
Songmu committed Jul 20, 2015
1 parent 3803511 commit c254b10
Show file tree
Hide file tree
Showing 10 changed files with 78 additions and 64 deletions.
33 changes: 13 additions & 20 deletions Build.PL
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,6 @@ use utf8;
use Module::Build;
use File::Basename;
use File::Spec;
use CPAN::Meta;
use CPAN::Meta::Prereqs;

my %args = (
license => 'perl',
Expand All @@ -34,7 +32,7 @@ my %args = (
test_files => ((-d '.git' || $ENV{RELEASE_TESTING}) && -d 'xt') ? 't/ xt/' : 't/',
recursive_test_files => 1,


);
if (-d 'share') {
$args{share_dir} = 'share';
Expand All @@ -53,20 +51,15 @@ my $builder = Module::Build->subclass(
)->new(%args);
$builder->create_build_script();

my $mbmeta = CPAN::Meta->load_file('MYMETA.json');
my $meta = CPAN::Meta->load_file('META.json');
my $prereqs_hash = CPAN::Meta::Prereqs->new(
$meta->prereqs
)->with_merged_prereqs(
CPAN::Meta::Prereqs->new($mbmeta->prereqs)
)->as_string_hash;
my $mymeta = CPAN::Meta->new(
{
%{$meta->as_struct},
prereqs => $prereqs_hash
}
);
print "Merging cpanfile prereqs to MYMETA.yml\n";
$mymeta->save('MYMETA.yml', { version => 1.4 });
print "Merging cpanfile prereqs to MYMETA.json\n";
$mymeta->save('MYMETA.json', { version => 2 });
use File::Copy;

print "cp META.json MYMETA.json\n";
copy("META.json","MYMETA.json") or die "Copy failed(META.json): $!";

if (-f 'META.yml') {
print "cp META.yml MYMETA.yml\n";
copy("META.yml","MYMETA.yml") or die "Copy failed(META.yml): $!";
} else {
print "There is no META.yml... You may install this module from the repository...\n";
}

5 changes: 4 additions & 1 deletion Changes
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@ Revision history for Perl extension HTML::Shakan

{{$NEXT}}

2.01 2015-07-20T15:40:39Z
- Introduce Model::Teng (GeJ++)

2.00 2013-11-20T07:22:24Z
- Bump up major version

Expand All @@ -18,7 +21,7 @@ Revision history for Perl extension HTML::Shakan
- Use HTML::Escape while escaping HTML chars.
It makes HTML::Shakan faster.

You need to care while updating this module.
You need to care while updating this module.
HTML::Escape escapes more characters by default.
(Masayuki Matsuki)

Expand Down
37 changes: 24 additions & 13 deletions META.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"Tokuhiro Matsuno <tokuhirom @ gmail.com>"
],
"dynamic_config" : 0,
"generated_by" : "Minilla/v0.8.2, CPAN::Meta::Converter version 2.132510",
"generated_by" : "Minilla/v2.3.0, CPAN::Meta::Converter version 2.142060",
"license" : [
"perl_5"
],
Expand All @@ -28,17 +28,28 @@
"prereqs" : {
"configure" : {
"requires" : {
"CPAN::Meta" : "0",
"CPAN::Meta::Prereqs" : "0",
"Module::Build" : "0.38"
}
},
"develop" : {
"requires" : {
"recommends" : {
"Perl::Critic" : "1.105",
"Test::Perl::Critic" : "1.02"
},
"requires" : {
"DBD::SQLite" : "1.31",
"DBIx::Skinny" : "0.0740",
"Data::Model" : "0",
"DateTime" : "0",
"DateTime::Format::HTTP" : "0",
"HTTP::Request::Common" : "0",
"Lingua::JA::Regular::Unicode" : "0",
"Plack::Request" : "0",
"Plack::Test" : "0",
"Teng" : "0.28",
"Test::CPAN::Meta" : "0",
"Test::MinimumVersion" : "0.10108",
"Test::Perl::Critic" : "1.02",
"Test::MinimumVersion::Fast" : "0.04",
"Test::PAUSE::Permissions" : "0.04",
"Test::Pod" : "1.41",
"Test::Spellunker" : "v0.2.7"
},
Expand All @@ -51,9 +62,7 @@
"DateTime" : "0",
"DateTime::Format::HTTP" : "0",
"HTML::Scrubber" : "0",
"Lingua::JA::Regular::Unicode" : "0",
"Mouse::Role" : "0",
"Scalar::Util" : "0"
"Lingua::JA::Regular::Unicode" : "0"
},
"requires" : {
"Email::Valid::Loose" : "0.05",
Expand All @@ -63,6 +72,7 @@
"List::MoreUtils" : "0.22",
"List::Util" : "1.32",
"Mouse" : "0.9",
"Scalar::Util" : "0",
"parent" : "0",
"perl" : "5.008001"
}
Expand All @@ -72,9 +82,9 @@
"DBIx::Skinny" : "0",
"DBIx::Skinny::Row" : "0",
"DBIx::Skinny::Schema" : "0",
"HTTP::Request::Common" : "0",
"Plack::Request" : "0",
"Plack::Test" : "0"
"Teng" : "0",
"Teng::Row" : "0",
"Teng::Schema::Declare" : "0"
},
"requires" : {
"CGI" : "0",
Expand All @@ -95,14 +105,15 @@
"web" : "https://github.com/Songmu/html-shakan"
}
},
"version" : "2.00",
"version" : "2.01",
"x_contributors" : [
"gfx <gfuji@cpan.org>",
"Yoshihiro Sasaki <aloelight@gmail.com>",
"Nobuo Danjou <nobuo.danjou@gmail.com>",
"toritori0318 <toritori0318@gmail.com>",
"moznion <moznion@gmail.com>",
"tokuhirom <tokuhirom@gmail.com>",
"Geraud CONTINSOUZAS <geraud@scsi.nc>",
"Songmu <y.songmu@gmail.com>"
]
}
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
[![Build Status](https://travis-ci.org/Songmu/html-shakan.png?branch=master)](https://travis-ci.org/Songmu/html-shakan) [![Coverage Status](https://coveralls.io/repos/Songmu/html-shakan/badge.png?branch=master)](https://coveralls.io/r/Songmu/html-shakan?branch=master)
[![Build Status](https://travis-ci.org/Songmu/html-shakan.svg?branch=master)](https://travis-ci.org/Songmu/html-shakan) [![Coverage Status](https://img.shields.io/coveralls/Songmu/html-shakan/master.svg)](https://coveralls.io/r/Songmu/html-shakan?branch=master)
# NAME

HTML::Shakan - Form HTML generator/validator
Expand Down Expand Up @@ -95,7 +95,7 @@ THIS IS BETA.API WILL CHANGE.

- `params`

Returns form parameters. It is [Hash::MultiValue](http://search.cpan.org/perldoc?Hash::MultiValue) object.
Returns form parameters. It is [Hash::MultiValue](https://metacpan.org/pod/Hash::MultiValue) object.

# benchmarking

Expand All @@ -122,7 +122,7 @@ If you want to know about shakan, please see [http://ja.wikipedia.org/wiki/%E5%B

- `$shakan->render_field($name); :Str`

Render partial form named `<$name`\>.
Render partial form named `<$name`>.

- `$shakan->param($key:Str); :Value[s]`

Expand All @@ -135,7 +135,7 @@ Tokuhiro Matsuno <tokuhirom @ gmail.com>

# SEE ALSO

[HTML::FormFu](http://search.cpan.org/perldoc?HTML::FormFu)
[HTML::FormFu](https://metacpan.org/pod/HTML::FormFu)

ToscaWidgets

Expand Down
35 changes: 21 additions & 14 deletions cpanfile
Original file line number Diff line number Diff line change
@@ -1,19 +1,23 @@
requires 'Email::Valid::Loose', '0.05';
requires 'FormValidator::Lite', '0.24';
requires 'Hash::MultiValue';
requires 'HTML::Escape';
requires 'Hash::MultiValue';
requires 'List::MoreUtils', '0.22';
requires 'List::Util', '1.32';
requires 'Mouse', '0.9';
requires 'Scalar::Util';
requires 'parent';
requires 'perl', '5.008001';

recommends 'DateTime';
recommends 'DateTime::Format::HTTP';
recommends 'HTML::Scrubber';
recommends 'Lingua::JA::Regular::Unicode';
recommends 'Mouse::Role';
recommends 'Scalar::Util';


on configure => sub {
requires 'Module::Build';
};

on test => sub {
requires 'CGI';
Expand All @@ -22,20 +26,23 @@ on test => sub {
recommends 'DBIx::Skinny';
recommends 'DBIx::Skinny::Row';
recommends 'DBIx::Skinny::Schema';
recommends 'HTTP::Request::Common';
recommends 'Plack::Request';
recommends 'Plack::Test';
recommends 'Teng';
};

on configure => sub {
requires 'CPAN::Meta';
requires 'CPAN::Meta::Prereqs';
requires 'Module::Build';
recommends 'Teng::Row';
recommends 'Teng::Schema::Declare';
};

on develop => sub {
requires 'Perl::Critic', '1.105';
requires 'Test::Perl::Critic', '1.02';
requires 'DBD::SQLite', '1.31';
requires 'DBIx::Skinny', '0.0740';
requires 'Data::Model';
requires 'DateTime';
requires 'DateTime::Format::HTTP';
requires 'HTTP::Request::Common';
requires 'Lingua::JA::Regular::Unicode';
requires 'Plack::Request';
requires 'Plack::Test';
requires 'Teng', '0.28';
recommends 'Perl::Critic', '1.105';
recommends 'Test::Perl::Critic', '1.02';
suggests 'HTML::FormFu';
};
8 changes: 4 additions & 4 deletions lib/HTML/Shakan.pm
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
package HTML::Shakan;
use strict;
use warnings;
use Mouse;
our $VERSION = '2.00';
use Mouse 0.9;
our $VERSION = '2.01';
use Carp ();
use 5.008001;

use FormValidator::Lite 'Email', 'URL', 'Date', 'File';
use FormValidator::Lite 0.24 'Email', 'URL', 'Date', 'File';
use Hash::MultiValue;

use HTML::Shakan::Renderer::HTML;
Expand All @@ -17,7 +17,7 @@ use HTML::Shakan::Field::Input;
use HTML::Shakan::Field::Date;
use HTML::Shakan::Field::Choice;
use HTML::Shakan::Field::File;
use List::MoreUtils 'uniq';
use List::MoreUtils 0.22 'uniq';

sub import {
HTML::Shakan::Fields->export_to_level(1);
Expand Down
2 changes: 1 addition & 1 deletion lib/HTML/Shakan/Field/Choice.pm
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ package HTML::Shakan::Field::Choice;
use strict;
use warnings;

use List::Util qw/pairmap/;
use List::Util 1.32 qw/pairmap/;

use Mouse;
extends 'HTML::Shakan::Field';
Expand Down
10 changes: 5 additions & 5 deletions lib/HTML/Shakan/Model/Teng.pm
Original file line number Diff line number Diff line change
Expand Up @@ -76,21 +76,21 @@ insert/fill/update by L<HTML::Shakan>.
=over 4
=item $form->model->fill($row);
=item C<< $form->model->fill($row); >>
fill the $row data to form.$row is instance of row class of Teng.
=item my $row = $form->model->create($teng, $table);
=item C<< my $row = $form->model->create($teng, $table); >>
insert form data to $table.
=item my $row = $form->model->insert($teng, $table);
=item C<< my $row = $form->model->insert($teng, $table); >>
insert method is synonym of create method.
=item $form->model->update($row);
=item C<< $form->model->update($row); >>
update $row by form data.
update C<$row> by form data.
=back
Expand Down
2 changes: 1 addition & 1 deletion t/00_compile.t
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
use strict;
use Test::More tests => 1;
use Test::More 0.98 tests => 1;

BEGIN { use_ok 'HTML::Shakan' }
2 changes: 1 addition & 1 deletion t/upload_submitted.t
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
use strict;
use warnings;
use HTML::Shakan;
use Test::Requires 'Plack::Test', 'Plack::Request', 'HTTP::Request::Common';
use Test::Requires 0.06 'Plack::Test', 'Plack::Request', 'HTTP::Request::Common';
use Test::More;

my $app = sub {
Expand Down

0 comments on commit c254b10

Please sign in to comment.