[med-svn] [librg-exception-perl] 10/15: New upstream version 1.0.3
Andreas Tille
tille at debian.org
Tue Nov 28 07:08:52 UTC 2017
This is an automated email from the git hooks/post-receive script.
tille pushed a commit to branch master
in repository librg-exception-perl.
commit da54de5143833e46598295dabc97a70c5123f6d0
Author: Andreas Tille <tille at debian.org>
Date: Tue Nov 28 08:02:59 2017 +0100
New upstream version 1.0.3
---
Build.PL | 15 +++++++++
Changes | 20 +++++++++++
MANIFEST | 7 ++++
MANIFEST.SKIP | 50 ++++++++++++++++++++++++++++
META.json | 44 ++++++++++++++++++++++++
META.yml | 27 +++++++++++++++
debian/changelog | 19 -----------
debian/compat | 1 -
debian/control | 27 ---------------
debian/copyright | 30 -----------------
debian/rules | 6 ----
debian/source/format | 1 -
debian/watch | 2 --
lib/RG/Exception.pm | 94 ++++++++++++++++++++++++++++++++++++++++++++++++++++
14 files changed, 257 insertions(+), 86 deletions(-)
diff --git a/Build.PL b/Build.PL
new file mode 100644
index 0000000..70d2b00
--- /dev/null
+++ b/Build.PL
@@ -0,0 +1,15 @@
+use warnings;
+use strict;
+use Module::Build;
+
+Module::Build->new(
+ module_name => 'RG::Exception',
+ license => 'perl',
+ configure_requires => { 'Module::Build' => 0.38 },
+ dist_name => 'librg-exception-perl',
+ dist_version => '1.0.3',
+ dist_author => [ 'Laszlo Kajan <lkajan at rostlab.org>' ],
+ dist_abstract => 'This package provides the RG::Exception module used in certain scripts from the Rost Lab.'
+)->create_build_script;
+
+# vim:et:ts=2:ai:
diff --git a/Changes b/Changes
new file mode 100644
index 0000000..e0ec939
--- /dev/null
+++ b/Changes
@@ -0,0 +1,20 @@
+librg-exception-perl (1.0.3) unstable; urgency=low
+
+ * Added Changes change log to package.
+ * Corrected and added license (perl_5).
+
+ -- Laszlo Kajan <lkajan at rostlab.org> Wed, 11 Jul 2012 14:31:39 +0200
+
+librg-exception-perl (1.0.2) unstable; urgency=low
+
+ * Debianization moved out for packaging.
+
+ -- Laszlo Kajan <lkajan at rostlab.org> Tue, 03 Jul 2012 13:29:45 +0200
+
+librg-exception-perl (1.0.1) unstable; urgency=low
+
+ * New package for RG::Exception
+
+ -- Laszlo Kajan <lkajan at rostlab.org> Wed, 19 Oct 2011 16:13:12 +0200
+
+# vim:textwidth=78:
diff --git a/MANIFEST b/MANIFEST
new file mode 100644
index 0000000..4ab403a
--- /dev/null
+++ b/MANIFEST
@@ -0,0 +1,7 @@
+Build.PL
+Changes
+lib/RG/Exception.pm
+MANIFEST This list of files
+MANIFEST.SKIP
+META.yml
+META.json
diff --git a/MANIFEST.SKIP b/MANIFEST.SKIP
new file mode 100644
index 0000000..7458377
--- /dev/null
+++ b/MANIFEST.SKIP
@@ -0,0 +1,50 @@
+\bdebian/
+
+#!start included /usr/share/perl/5.10/ExtUtils/MANIFEST.SKIP
+# Avoid version control files.
+\bRCS\b
+\bCVS\b
+\bSCCS\b
+,v$
+\B\.svn\b
+\B\.git\b
+\B\.gitignore\b
+\b_darcs\b
+
+# Avoid Makemaker generated and utility files.
+\bMANIFEST\.bak
+\bMakefile$
+\bblib/
+\bMakeMaker-\d
+\bpm_to_blib\.ts$
+\bpm_to_blib$
+\bblibdirs\.ts$ # 6.18 through 6.25 generated this
+
+# Avoid Module::Build generated and utility files.
+\bBuild$
+\b_build/
+
+# Avoid temp and backup files.
+~$
+\.old$
+\#$
+\b\.#
+\.bak$
+
+# Avoid Devel::Cover files.
+\bcover_db\b
+#!end included /usr/share/perl/5.10/ExtUtils/MANIFEST.SKIP
+
+
+# Avoid Module::Build generated and utility files.
+\bBuild$
+\bBuild.bat$
+\b_build
+\bBuild.COM$
+\bBUILD.COM$
+\bbuild.com$
+
+# Avoid archives of this distribution
+\blibrg-exception-perl-[\d\.\_]+
+^MYMETA\.yml$
+^MYMETA\.json$
diff --git a/META.json b/META.json
new file mode 100644
index 0000000..7cd2074
--- /dev/null
+++ b/META.json
@@ -0,0 +1,44 @@
+{
+ "abstract" : "This package provides the RG::Exception module used in certain scripts from the Rost Lab.",
+ "author" : [
+ "Laszlo Kajan <lkajan at rostlab.org>"
+ ],
+ "dynamic_config" : 1,
+ "generated_by" : "Module::Build version 0.38, CPAN::Meta::Converter version 2.110440",
+ "license" : [
+ "perl_5"
+ ],
+ "meta-spec" : {
+ "url" : "http://search.cpan.org/perldoc?CPAN::Meta::Spec",
+ "version" : "2"
+ },
+ "name" : "librg-exception-perl",
+ "prereqs" : {
+ "configure" : {
+ "requires" : {
+ "Module::Build" : "0.38"
+ }
+ }
+ },
+ "provides" : {
+ "RG::Exception" : {
+ "file" : "lib/RG/Exception.pm",
+ "version" : 0
+ },
+ "RG::Exception::NotImplemented" : {
+ "file" : "lib/RG/Exception.pm",
+ "version" : 0
+ },
+ "RG::Exception::SyntaxError" : {
+ "file" : "lib/RG/Exception.pm",
+ "version" : 0
+ }
+ },
+ "release_status" : "stable",
+ "resources" : {
+ "license" : [
+ "http://dev.perl.org/licenses/"
+ ]
+ },
+ "version" : "v1.0.3"
+}
diff --git a/META.yml b/META.yml
new file mode 100644
index 0000000..b350af1
--- /dev/null
+++ b/META.yml
@@ -0,0 +1,27 @@
+---
+abstract: 'This package provides the RG::Exception module used in certain scripts from the Rost Lab.'
+author:
+ - 'Laszlo Kajan <lkajan at rostlab.org>'
+build_requires: {}
+configure_requires:
+ Module::Build: 0.38
+dynamic_config: 1
+generated_by: 'Module::Build version 0.38, CPAN::Meta::Converter version 2.110440'
+license: perl
+meta-spec:
+ url: http://module-build.sourceforge.net/META-spec-v1.4.html
+ version: 1.4
+name: librg-exception-perl
+provides:
+ RG::Exception:
+ file: lib/RG/Exception.pm
+ version: 0
+ RG::Exception::NotImplemented:
+ file: lib/RG/Exception.pm
+ version: 0
+ RG::Exception::SyntaxError:
+ file: lib/RG/Exception.pm
+ version: 0
+resources:
+ license: http://dev.perl.org/licenses/
+version: v1.0.3
diff --git a/debian/changelog b/debian/changelog
deleted file mode 100644
index dcba2fc..0000000
--- a/debian/changelog
+++ /dev/null
@@ -1,19 +0,0 @@
-librg-exception-perl (1.0.3-2) unstable; urgency=medium
-
- [ Damyan Ivanov ]
- * Add build dependency on libmodule-build-perl
- Closes: #789409 -- FTBFS with perl 5.22
-
- [ Andreas Tille ]
- * cme fix dpkg-control
- * Debhelper 9
- * Priority: optional
-
- -- Andreas Tille <tille at debian.org> Fri, 24 Jul 2015 15:21:21 +0200
-
-librg-exception-perl (1.0.3-1) unstable; urgency=low
-
- * Initial release (Closes: #681098)
-
- -- Ariane Boehm <boehma at in.tum.de> Tue, 10 Jul 2012 15:34:57 +0000
-
diff --git a/debian/compat b/debian/compat
deleted file mode 100644
index ec63514..0000000
--- a/debian/compat
+++ /dev/null
@@ -1 +0,0 @@
-9
diff --git a/debian/control b/debian/control
deleted file mode 100644
index e299e60..0000000
--- a/debian/control
+++ /dev/null
@@ -1,27 +0,0 @@
-Source: librg-exception-perl
-Maintainer: Debian Med Packaging Team <debian-med-packaging at lists.alioth.debian.org>
-Uploaders: Ariane Boehm <boehma at in.tum.de>,
- Laszlo Kajan <lkajan at rostlab.org>,
- Andreas Tille <tille at debian.org>
-Section: perl
-Priority: optional
-Build-Depends: debhelper (>= 9)
-Build-Depends-Indep: perl,
- libmodule-build-perl
-Standards-Version: 3.9.6
-Vcs-Browser: http://anonscm.debian.org/viewvc/debian-med/trunk/packages/librg-exception-perl/trunk/
-Vcs-Svn: svn://anonscm.debian.org/debian-med/trunk/packages/librg-exception-perl/trunk/
-Homepage: http://rostlab.org/
-
-Package: librg-exception-perl
-Architecture: all
-Depends: ${misc:Depends},
- ${perl:Depends}
-Description: RG::Exception Perl module
- This package provides the RG::Exception Perl module, required by certain
- tools from the Rost Lab.
- .
- The following exceptions are implemented:
- * RG::Exception
- * RG::Exception::NotImplemented
- * RG::Exception::SyntaxError
diff --git a/debian/copyright b/debian/copyright
deleted file mode 100644
index 5d70484..0000000
--- a/debian/copyright
+++ /dev/null
@@ -1,30 +0,0 @@
-Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/
-Upstream-Name: librg-exception-perl
-Upstream-Contact: Laszlo Kajan <lkajan at rostlab.org>
-Source: ftp://rostlab.org/librg-exception-perl/
-
-Files: *
-Copyright: 2008 <lkajan at rostlab.org>
-License: Artistic or GPL-1+
-
-Files: debian/*
-Copyright: 2011 Laszlo Kajan <lkajan at rostlab.org> Technical University of Munich, Germany
- 2012 Ariane Boehm <boehma at in.tum.de>
-License: Artistic or GPL-1+
-
-License: Artistic
- This program is free software; you can redistribute it and/or modify
- it under the terms of the Artistic License, which comes with Perl.
- .
- On Debian systems, the complete text of the Artistic License can be
- found in `/usr/share/common-licenses/Artistic'.
-
-License: GPL-1+
- This program is free software; you can redistribute it and/or modify
- it under the terms of the GNU General Public License as published by
- the Free Software Foundation; either version 1, or (at your option)
- any later version.
- .
- On Debian systems, the complete text of version 1 of the GNU General
- Public License can be found in `/usr/share/common-licenses/GPL-1'.
-
diff --git a/debian/rules b/debian/rules
deleted file mode 100755
index 5425b7f..0000000
--- a/debian/rules
+++ /dev/null
@@ -1,6 +0,0 @@
-#!/usr/bin/make -f
-# Uncomment this to turn on verbose mode.
-#export DH_VERBOSE=1
-
-%:
- dh $@
diff --git a/debian/source/format b/debian/source/format
deleted file mode 100644
index 163aaf8..0000000
--- a/debian/source/format
+++ /dev/null
@@ -1 +0,0 @@
-3.0 (quilt)
diff --git a/debian/watch b/debian/watch
deleted file mode 100644
index 3115625..0000000
--- a/debian/watch
+++ /dev/null
@@ -1,2 +0,0 @@
-version=3
-ftp://rostlab.org/librg-exception-perl/librg-exception-perl-([0-9.]+)\.tar\.gz
diff --git a/lib/RG/Exception.pm b/lib/RG/Exception.pm
new file mode 100644
index 0000000..ef32380
--- /dev/null
+++ b/lib/RG/Exception.pm
@@ -0,0 +1,94 @@
+package RG::Exception;
+##############################################################################
+#
+# Copyright: 2008 László Kaján
+#
+# License: This program is free software; you can redistribute it and/or
+# modify it under the same terms as Perl itself, either Perl version 5.8.8 or,
+# at your option, any later version of Perl 5 you may have available.
+#
+##############################################################################
+# RG exception base class
+# Typical use:
+# die RG::Exception->new( { msg => 'error message' } );
+##############################################################################
+use strict;
+use Carp;
+$Carp::CarpInternal{ 'RG::Exception' }++;
+
+sub new
+{
+ my $this = shift;
+ my $class = ref($this) || $this;
+ my $self = {};
+ bless $self, $class;
+ $self->_initialize( @_ );
+ return $self;
+}
+
+
+sub _initialize # protected method
+{
+ my( $self, %__p ) = @_;
+ # { msg => str }
+
+ if( !$__p{msg} ) { $__p{msg} = ''; }
+
+ # set properties
+ while( my( $key, $val ) = each( %__p ) ) { $self->$key( $val ); }
+}
+
+
+# Overloaded string conversion operator. Returns "Uncaught exception 'REFERENCE':".msg(). Normally you would catch the exception and emit the message msg() of it.
+use overload '""' => sub{ return 'Uncaught exception \''.ref($_[0])."\':\n".$_[0]->msg_stack_backtrace(); };
+
+
+sub msg # error message
+{
+ if( @_ > 1 )
+ {
+ $_[0]->msg_stack_backtrace( Carp::longmess( $_[1] ) );
+ return $_[0]->{_msg} = Carp::shortmess( $_[1] );
+ }
+ else
+ {
+ return $_[0]->{_msg};
+ }
+}
+
+
+# Error message appended with the output of Carp::longmess(), a stack backtrace. See: L<Carp>.
+sub msg_stack_backtrace # error message
+{ return ( @_ > 1 ? $_[0]->{_msg_stack_backtrace} = $_[1] : $_[0]->{_msg_stack_backtrace} ); }
+
+
+package RG::Exception::NotImplemented;
+use strict;
+use Carp;
+$Carp::CarpInternal{ 'RG::Exception::NotImplemented' }++;
+use base qw( RG::Exception ); # inheritance
+##############################################################################
+# Typical use:
+# die RG::Exception::NotImplemented->new();
+##############################################################################
+sub _initialize # protected method
+{
+ my( $self ) = @_;
+
+ $self->SUPER::_initialize( msg => 'not implemented' );
+}
+
+
+package RG::Exception::SyntaxError;
+use strict;
+use Carp;
+$Carp::CarpInternal{ 'RG::Exception::SyntaxError' }++;
+use base qw( RG::Exception ); # inheritance
+##############################################################################
+# Typical use:
+# die RG::Exception::Parser::SyntaxError->new( { msg => 'syntax error on line $lineno' } );
+##############################################################################
+
+1;
+
+# vim:et:ts=2:ai:
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-med/librg-exception-perl.git
More information about the debian-med-commit
mailing list