]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - make/unit-cc.pl
Implement support for multi-prefix on WHOIS.
[user/henk/code/inspircd.git] / make / unit-cc.pl
index d577022dad8c2f3be57b9087b7e23f9c1195f575..f555c3812f9814d833a8d4f2f69b41ce53b77885 100755 (executable)
@@ -1,5 +1,4 @@
 #!/usr/bin/env perl
-
 #
 # InspIRCd -- Internet Relay Chat Daemon
 #
 #
 
 
-BEGIN {
-       push @INC, $ENV{SOURCEPATH};
-       require 5.10.0;
-}
-
+use v5.10.0;
 use strict;
 use warnings FATAL => qw(all);
 
+use File::Basename        qw(dirname);
 use File::Spec::Functions qw(abs2rel);
+use FindBin               qw($RealDir);
 
+use lib dirname $RealDir;
 use make::console;
 use make::directive;
 
@@ -59,9 +57,9 @@ exit 1;
 sub message($$$) {
        my ($type, $file, $command) = @_;
        if ($ENV{INSPIRCD_VERBOSE}) {
-               print "$command\n";
+               say $command;
        } else {
-               print_format "\t<|GREEN $type:|>\t\t$file\n";
+               say console_format "\t<|GREEN $type:|>\t\t$file";
        }
 }