Permalink
Browse files

initial commit

  • Loading branch information...
0 parents commit a1c64240a338eacc3606674693a57fc81453292b @xaicron committed Jul 8, 2011
Showing with 218 additions and 0 deletions.
  1. +20 −0 .gitignore
  2. +2 −0 .shipit
  3. +4 −0 Changes
  4. +15 −0 MANIFEST.SKIP
  5. +15 −0 Makefile.PL
  6. +27 −0 README
  7. +42 −0 lib/App/envfile.pm
  8. +5 −0 t/00_compile.t
  9. +37 −0 xt/01_podspell.t
  10. +6 −0 xt/02_pod.t
  11. +11 −0 xt/03_pod-coverage.t
  12. +13 −0 xt/04_perlcritic.t
  13. +18 −0 xt/05_script-shebang.t
  14. +3 −0 xt/perlcriticrc
20 .gitignore
@@ -0,0 +1,20 @@
+cover_db
+MYMETA.yml
+META.yml
+Makefile
+blib
+inc
+pm_to_blib
+MANIFEST
+MANIFEST.bak
+Makefile.old
+nytprof*
+ppport.h
+xs/*c
+xs/*o
+xs/*obj
+*.bs
+*.def
+*.old
+dll*
+*~
2 .shipit
@@ -0,0 +1,2 @@
+steps = FindVersion, ChangeVersion, CheckChangeLog, DistTest, Commit, Tag, MakeDist, UploadCPAN
+git.push_to = origin
4 Changes
@@ -0,0 +1,4 @@
+Revision history for Perl extension App::envfile
+
+0.01 Fri Jul 8 20:16:56 2011
+ - original version
15 MANIFEST.SKIP
@@ -0,0 +1,15 @@
+\bRCS\b
+\bCVS\b
+\.svn/
+\.git/
+^MANIFEST\.
+^Makefile$
+~$
+\.old$
+^blib/
+^pm_to_blib
+^MakeMaker-\d
+\.gz$
+\.shipit
+\.gitignore
+\ppport.h
15 Makefile.PL
@@ -0,0 +1,15 @@
+use inc::Module::Install;
+name 'App-envfile';
+all_from 'lib/App/envfile.pm';
+
+#requires '';
+
+#build_requires '';
+test_requires 'Test::More', 0.96;
+
+tests join q{ }, map { sprintf 't%s.t', '/*' x $_ } 1..3;
+author_tests 'xt';
+
+auto_set_repository();
+
+WriteAll;
27 README
@@ -0,0 +1,27 @@
+This is Perl module App::envfile.
+
+INSTALLATION
+
+App::envfile installation is straightforward. If your CPAN shell is set up,
+you should just be able to do
+
+ % cpan App::envfile
+
+Download it, unpack it, then build it as per the usual:
+
+ % perl Makefile.PL
+ % make && make test
+
+Then install it:
+
+ % make install
+
+DOCUMENTATION
+
+App::envfile documentation is available as in POD. So you can do:
+
+ % perldoc App::envfile
+
+to read the documentation online with your favorite pager.
+
+xaicron
42 lib/App/envfile.pm
@@ -0,0 +1,42 @@
+package App::envfile;
+
+use strict;
+use warnings;
+use 5.008_001;
+our $VERSION = '0.01';
+
+1;
+__END__
+
+=encoding utf-8
+
+=for stopwords
+
+=head1 NAME
+
+App::envfile -
+
+=head1 SYNOPSIS
+
+ use App::envfile;
+
+=head1 DESCRIPTION
+
+App::envfile is
+
+=head1 AUTHOR
+
+xaicron E<lt>xaicron@cpan.orgE<gt>
+
+=head1 COPYRIGHT
+
+Copyright 2011 - xaicron
+
+=head1 LICENSE
+
+This library is free software; you can redistribute it and/or modify
+it under the same terms as Perl itself.
+
+=head1 SEE ALSO
+
+=cut
5 t/00_compile.t
@@ -0,0 +1,5 @@
+use strict;
+use warnings;
+use Test::More tests => 1;
+
+BEGIN { use_ok 'App::envfile' }
37 xt/01_podspell.t
@@ -0,0 +1,37 @@
+use strict;
+use warnings;
+use Test::More;
+use Test::Requires 'Test::Spelling';
+use Config;
+use File::Spec;
+use ExtUtils::MakeMaker;
+
+my %cmd_map = (
+ spell => 'spell',
+ aspell => 'aspell list -l en',
+ ispell => 'ispell -l',
+ hunspell => 'hunspell -d en_US -l',
+);
+
+my $spell_cmd;
+for my $dir ((split /$Config::Config{path_sep}/, $ENV{PATH}), '.') {
+ next if $dir eq '';
+ ($spell_cmd) = map { $cmd_map{$_} } grep {
+ my $abs = File::Spec->catfile($dir, $_);
+ -x $abs or MM->maybe_command($abs);
+ } keys %cmd_map;
+ last if $spell_cmd;
+}
+$spell_cmd = $ENV{SPELL_CMD} if $ENV{SPELL_CMD};
+plan skip_all => "spell command are not available." unless $spell_cmd;
+add_stopwords(map { split /[\s\:\-]/ } <DATA>);
+set_spell_cmd($spell_cmd);
+$ENV{LANG} = 'C';
+all_pod_files_spelling_ok('lib');
+
+__DATA__
+App::envfile
+
+# personal section
+xaicron
+xaicron@cpan.org
6 xt/02_pod.t
@@ -0,0 +1,6 @@
+use strict;
+use warnings;
+use Test::More;
+use Test::Requires { 'Test::Pod' => 1.00 };
+
+all_pod_files_ok();
11 xt/03_pod-coverage.t
@@ -0,0 +1,11 @@
+use strict;
+use warnings;
+use Test::More;
+use Test::Requires { 'Test::Pod::Coverage' => 1.04 };
+
+unless ($ENV{TEST_POD_COVERAGE}) {
+ plan skip_all => "\$ENV{TEST_POD_COVERAGE} is not set.";
+ exit;
+}
+
+all_pod_coverage_ok({also_private => [qw(unimport BUILD DEMOLISH)]});
13 xt/04_perlcritic.t
@@ -0,0 +1,13 @@
+use strict;
+use warnings;
+use Test::More;
+use Test::Requires { 'Test::Perl::Critic' => 1.02 };
+
+unless ($ENV{TEST_PERLCRITIC}) {
+ plan skip_all => "\$ENV{TEST_PERLCRITIC} is not set.";
+ exit;
+}
+
+Test::Perl::Critic->import( -profile => 'xt/perlcriticrc');
+
+all_critic_ok('lib');
18 xt/05_script-shebang.t
@@ -0,0 +1,18 @@
+use strict;
+use warnings;
+use Test::More;use Test::Requires 'Test::Script::Shebang';
+use File::Find qw/find/;
+
+my @files;
+for my $dir (qw/bin script/) {
+ next unless -d $dir;
+ find +{
+ no_chdir => 1,
+ wanted => sub { push @files, $_ if -f },
+ }, $dir;
+}
+plan skip_all => 'script not found' unless @files;
+
+check_shebang(@files);
+
+done_testing;
3 xt/perlcriticrc
@@ -0,0 +1,3 @@
+[TestingAndDebugging::ProhibitNoStrict]
+allow=refs
+[-Subroutines::ProhibitSubroutinePrototypes]

0 comments on commit a1c6424

Please sign in to comment.