7
use lib '@LR_PERL5LIBDIR@';
9
use Lire::Program qw( :msg $PROG );
10
use Lire::PluginManager;
13
lr_err( "Usage: $PROG <service>|-l" ) unless @ARGV == 1;
15
if ($ARGV[0] eq '-l') {
16
print join( "\n", Lire::DlfSchema->superservices() );
20
Lire::PluginManager->register_default_plugins();
21
if ( Lire::PluginManager->has_plugin( 'dlf_converter', $service ) ) {
23
Lire::PluginManager->get_plugin( 'dlf_converter', $service );
24
print join( ",", $converter->schemas() ), "\n";
27
'$service' isn't a known DLF converter.
28
Use lr_check_service -l to obtain the list of available converters.
40
lr_check_superservice - map Lire service to Lire superservice
44
B<lr_check_superservice> I<service>
45
B<lr_check_superservice> B<-l>
49
B<lr_check_superservice> takes a Lire service as argument, and returns the
50
I<superservice> this I<service> belongs to. In case the service is unknown, a
51
userfriendly errormessage is given.
53
When called with the B<-l> option, this script prints all supported
56
You might prefer the lr_log2report(1) --help options to list available
57
superservices: this command creates a more human-friendly format of the list.
61
Call this script in shell scripts as
65
LR_SUPERSERVICE=`lr_check_superservice "$LR_SERVICE" || true`
66
if test -z "$LR_SUPERSERVICE"
68
echo >&2 "$tag err lr_check_superservice failed"
72
# now go using $LR_SUPERSERVICE
76
Lire::PluginManager(3pm) Lire::DlfSchema(3pm)
80
$Id: lr_check_superservice.in,v 1.9 2004/09/04 10:34:59 vanbaal Exp $
84
Copyright (C) 2002-2003 Stichting LogReport Foundation LogReport@LogReport.org
86
This program is free software; you can redistribute it and/or modify
87
it under the terms of the GNU General Public License as published by
88
the Free Software Foundation; either version 2 of the License, or
89
(at your option) any later version.
91
This program is distributed in the hope that it will be useful,
92
but WITHOUT ANY WARRANTY; without even the implied warranty of
93
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
94
GNU General Public License for more details.
96
You should have received a copy of the GNU General Public License
97
along with this program (see COPYING); if not, check with
98
http://www.gnu.org/copyleft/gpl.html or write to the Free Software
99
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
103
Joost van Baal <joostvb@logreport.org>