Acme::SysPath - example distribution for Sys::Path


Acme-SysPath documentation Contained in the Acme-SysPath distribution.

Index


Code Index:

NAME

Top

Acme::SysPath - example distribution for Sys::Path

SYNOPSIS

Top

    use Acme::SysPath;
    print Acme::SysPath->config;
    print Acme::SysPath->template;
    print Acme::SysPath->image;
    use Data::Dumper; print "dump> ", Dumper(Acme::SysPath->paths), "\n";

FUNCTIONS

Top

paths

Returns sysconfdir and datadir in a hash.

config

Returns config file name.

template

Return template file name.

image

Return image.

AUTHOR

Top

Jozef Kutej, <jkutej at cpan.org>

BUGS

Top

Please report any bugs or feature requests to bug-acme-syspath at rt.cpan.org, or through the web interface at http://rt.cpan.org/NoAuth/ReportBug.html?Queue=Acme-SysPath. I will be notified, and then you'll automatically be notified of progress on your bug as I make changes.

SUPPORT

Top

You can find documentation for this module with the perldoc command.

    perldoc Acme::SysPath




You can also look for information at:

* RT: CPAN's request tracker

http://rt.cpan.org/NoAuth/Bugs.html?Dist=Acme-SysPath

* AnnoCPAN: Annotated CPAN documentation

http://annocpan.org/dist/Acme-SysPath

* CPAN Ratings

http://cpanratings.perl.org/d/Acme-SysPath

* Search CPAN

http://search.cpan.org/dist/Acme-SysPath

ACKNOWLEDGEMENTS

Top

COPYRIGHT & LICENSE

Top


Acme-SysPath documentation Contained in the Acme-SysPath distribution.
package Acme::SysPath;

use warnings;
use strict;

use Acme::SysPath::SPc;
use File::Spec;
use IO::Any;

our $VERSION = '0.05';


sub paths {
    return {
        'sysconfdir' => Acme::SysPath::SPc->sysconfdir,
        'datadir'    => Acme::SysPath::SPc->datadir,
    }
}

sub config {
    return File::Spec->catfile( Acme::SysPath::SPc->sysconfdir, 'acme-syspath.cfg' );
}

sub template {
    return File::Spec->catfile( Acme::SysPath::SPc->datadir, 'acme-syspath', 'tt', 'index.tt2' );
}

sub image {
    return IO::Any->slurp([ Acme::SysPath::SPc->datadir, 'acme-syspath', 'images', 'smile.ascii' ]);
}


1; # End of Acme::SysPath