$Config = get_config ();
}
+if ($ENV{'DEBUG'})
+{
+ require Data::Dumper;
+ print STDERR Data::Dumper->Dump ([$Config], ['Config']);
+}
+
unless (defined ($Config->{'uri'}) and defined ($Config->{'bind_dn'})
and defined ($Config->{'password'}))
{
print STDOUT scalar (@Matches), ' ', (scalar (@Matches) == 1 ? 'entry' : 'entries'), " found.\n";
-for (@Matches)
+for (sort { $a->name () cmp $b->name () } (@Matches))
{
my $person = $_;
my $cn = $person->name ();
my @mail = $person->get ('mail');
+ my @groups = $person->get ('group');
+ my $info = join (', ', sort (@groups));
+
+ $info = "($info)" if ($info);
- for (@mail)
+ for (sort (@mail))
{
- print "$_\t$cn\tFound by LiCoM\n";
+ print "$_\t$cn\t$info\n";
}
}