Removed /usr/local from CDPATH
[clearscm.git] / clearadm / tasks.cgi
1 #!/usr/local/bin/perl
2
3 =pod
4
5 =head1 NAME $RCSfile: tasks.cgi,v $
6
7 Display tasks
8
9 =head1 VERSION
10
11 =over
12
13 =item Author
14
15 Andrew DeFaria <Andrew@ClearSCM.com>
16
17 =item Revision
18
19 $Revision: 1.3 $
20
21 =item Created:
22
23 Mon Oct 25 11:10:47 PDT 2008
24
25 =item Modified:
26
27 $Date: 2011/01/27 01:15:13 $
28
29 =back
30
31 =head1 SYNOPSIS
32
33  Usage tasks.cgi: [-u|sage] [-ve|rbose] [-d|ebug]
34
35  Where:
36    -u|sage:               Displays usage
37    -ve|rbose:             Be verbose
38    -d|ebug:               Output debug messages
39
40 =head2 DESCRIPTION
41
42 This script displays tasks
43
44 =cut
45
46 use strict;
47 use warnings;
48
49 use FindBin;
50 use Getopt::Long;
51 use CGI qw (:standard :cgi-lib *table start_Tr end_Tr);
52 use CGI::Carp 'fatalsToBrowser';
53
54 use lib "$FindBin::Bin/lib", "$FindBin::Bin/../lib";
55
56 use Clearadm;
57 use ClearadmWeb;
58 use Display;
59 use Utils;
60
61 my $VERSION  = '$Revision: 1.3 $';
62   ($VERSION) = ($VERSION =~ /\$Revision: (.*) /);
63   
64 my $clearadm;
65
66 my %opts = Vars;
67
68 # Main
69 GetOptions (
70   usage      => sub { Usage },
71   verbose    => sub { set_verbose },
72   debug      => sub { set_debug },
73 ) or Usage 'Invalid parameter';
74
75 verbose "$FindBin::Script v$VERSION";
76
77 $clearadm = Clearadm->new;
78
79 my $title = $opts{task}
80           ? "Tasks matching $opts{task}"
81           : 'Tasks';
82
83 heading $title;
84
85 display h1 {class => 'center'}, $title;
86
87 displayTask ($opts{task});
88
89 footing;
90
91 =pod
92
93 =head1 CONFIGURATION AND ENVIRONMENT
94
95 DEBUG: If set then $debug is set to this level.
96
97 VERBOSE: If set then $verbose is set to this level.
98
99 TRACE: If set then $trace is set to this level.
100
101 =head1 DEPENDENCIES
102
103 =head2 Perl Modules
104
105 L<CGI>
106
107 L<CGI::Carp|CGI::Carp>
108
109 L<FindBin>
110
111 L<Getopt::Long|Getopt::Long>
112
113 =head2 ClearSCM Perl Modules
114
115 =begin man 
116
117  Clearadm
118  ClearadmWeb
119  Display
120  Utils
121
122 =end man
123
124 =begin html
125
126 <blockquote>
127 <a href="http://clearscm.com/php/scm_man.php?file=clearadm/lib/Clearadm.pm">Clearadm</a><br>
128 <a href="http://clearscm.com/php/scm_man.php?file=clearadm/lib/ClearadmWeb.pm">ClearadmWeb</a><br>
129 <a href="http://clearscm.com/php/scm_man.php?file=lib/Display.pm">Display</a><br>
130 <a href="http://clearscm.com/php/scm_man.php?file=lib/Utils.pm">Utils</a><br>
131 </blockquote>
132
133 =end html
134
135 =head1 BUGS AND LIMITATIONS
136
137 There are no known bugs in this script
138
139 Please report problems to Andrew DeFaria <Andrew@ClearSCM.com>.
140
141 =head1 LICENSE AND COPYRIGHT
142
143 Copyright (c) 2010, ClearSCM, Inc. All rights reserved.
144
145 =cut