aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--MANIFEST2
-rw-r--r--Makefile.PL2
-rw-r--r--lib/ManaTools/Version.pm80
-rw-r--r--t/00-load.t4
4 files changed, 85 insertions, 3 deletions
diff --git a/MANIFEST b/MANIFEST
index a43f2279..78962672 100644
--- a/MANIFEST
+++ b/MANIFEST
@@ -38,6 +38,7 @@ ignore.txt
lib/ManaTools/Category.pm
lib/ManaTools/ConfigDirRole.pm
lib/ManaTools/ConfigReader.pm
+lib/ManaTools/LoggingRole.pm
lib/ManaTools/MainDisplay.pm
lib/ManaTools/Module.pm
lib/ManaTools/Module/Clock.pm
@@ -83,6 +84,7 @@ lib/ManaTools/Shared/TimeZone.pm
lib/ManaTools/Shared/urpmi_backend/DB.pm
lib/ManaTools/Shared/urpmi_backend/tools.pm
lib/ManaTools/Shared/Users.pm
+lib/ManaTools/Version.pm
Makefile.PL
MANIFEST This list of files
MODULE_HACKING
diff --git a/Makefile.PL b/Makefile.PL
index 3bf0625d..105cce69 100644
--- a/Makefile.PL
+++ b/Makefile.PL
@@ -11,7 +11,7 @@ WriteMakefile(
NAME => 'ManaTools',
DISTNAME => 'manatools',
AUTHOR => q{Angelo Naselli <anaselli@linux.it> - Matteo Pasotti <matteo.pasotti@gmail.com>},
- VERSION_FROM => 'lib/ManaTools/MainDisplay.pm',
+ VERSION_FROM => 'lib/ManaTools/Version.pm',
ABSTRACT => 'ManaTools is a generic launcher application that can run perl modules or external programs using Suse YUI abstarction.',
LICENSE => 'GPL_2',
PL_FILES => {},
diff --git a/lib/ManaTools/Version.pm b/lib/ManaTools/Version.pm
new file mode 100644
index 00000000..fb956389
--- /dev/null
+++ b/lib/ManaTools/Version.pm
@@ -0,0 +1,80 @@
+# vim: set et ts=4 sw=4:
+package ManaTools::Version;
+#============================================================= -*-perl-*-
+
+=head1 NAME
+
+ Manatools::Version - Role to manage command line
+
+=head1 SYNOPSIS
+
+ package Foo;
+
+ use Moose;
+ with 'Manatools::Version';
+
+ 1;
+
+=head1 DESCRIPTION
+
+ Version just define a role in which command line is accessible.
+
+=head1 SUPPORT
+
+ You can find documentation for this module with the perldoc command:
+
+ perldoc Manatools::Version
+
+=head1 SEE ALSO
+
+=head1 AUTHOR
+
+Angelo Naselli <anaselli@linux.it>
+
+=head1 COPYRIGHT and LICENSE
+
+Copyright (C) 2015, Angelo Naselli.
+
+This module is free software. You can redistribute it and/or
+modify it under the terms of the Artistic License 2.0.
+
+This program is distributed in the hope that it will be
+useful, but without any warranty; without even the implied
+warranty of merchantability or fitness for a particular purpose
+
+=cut
+
+use Moose::Role;
+
+=head2 attributes
+
+=head3 definitions
+
+ Version: manatools common version override it
+ if you want your own versioning
+
+=cut
+#=============================================================
+
+=head1 VERSION
+
+ Version 1.1.0
+ See Changes for details
+
+=cut
+
+our $VERSION = '1.1.0';
+
+has 'Version' => (
+ is => 'ro',
+ isa => 'Str',
+ init_arg => undef,
+ default => sub {
+ return $VERSION;
+ }
+);
+
+
+no Moose::Role;
+
+1;
diff --git a/t/00-load.t b/t/00-load.t
index 4f28029b..f4d5c99e 100644
--- a/t/00-load.t
+++ b/t/00-load.t
@@ -7,8 +7,8 @@ use Test::More;
plan tests => 2;
BEGIN {
- use_ok( 'ManaTools::Shared' ) || print "ManaTools::Shared failed\n";
+ use_ok( 'ManaTools::Version' ) || print "ManaTools::Version failed\n";
use_ok( 'ManaTools::SettingsReader' ) || print "ManaTools::SettingsReader failed\n";
}
-diag( "Testing ManaTools::Shared $ManaTools::Shared::VERSION, Perl $], $^X" );
+diag( "Testing ManaTools::Shared $ManaTools::Version::VERSION, Perl $], $^X" );