Skip to content

Commit

Permalink
initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
xaicron committed Jul 8, 2011
0 parents commit a1c6424
Show file tree
Hide file tree
Showing 14 changed files with 218 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .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 changes: 2 additions & 0 deletions .shipit
@@ -0,0 +1,2 @@
steps = FindVersion, ChangeVersion, CheckChangeLog, DistTest, Commit, Tag, MakeDist, UploadCPAN
git.push_to = origin
4 changes: 4 additions & 0 deletions Changes
@@ -0,0 +1,4 @@
Revision history for Perl extension App::envfile

0.01 Fri Jul 8 20:16:56 2011
- original version
15 changes: 15 additions & 0 deletions 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 changes: 15 additions & 0 deletions 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 changes: 27 additions & 0 deletions 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 changes: 42 additions & 0 deletions 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 changes: 5 additions & 0 deletions t/00_compile.t
@@ -0,0 +1,5 @@
use strict;
use warnings;
use Test::More tests => 1;

BEGIN { use_ok 'App::envfile' }
37 changes: 37 additions & 0 deletions 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 changes: 6 additions & 0 deletions 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 changes: 11 additions & 0 deletions 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 changes: 13 additions & 0 deletions 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 changes: 18 additions & 0 deletions 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 changes: 3 additions & 0 deletions xt/perlcriticrc
@@ -0,0 +1,3 @@
[TestingAndDebugging::ProhibitNoStrict]
allow=refs
[-Subroutines::ProhibitSubroutinePrototypes]

0 comments on commit a1c6424

Please sign in to comment.