2 # Simple front-end to BitlBee's administration commands
3 # Copyright (C) 2006 Jelmer Vernooij <jelmer@samba.org>
11 my $opt_socketfile = "/var/run/bitlbee";
16 "bitlbee-ctl.pl [options] command ...
20 --ipc-socket=SOCKET Override path to IPC socket [$opt_socketfile]
21 --help Show this help message
32 'help|h|?' => \
&ShowHelp
,
33 'ipc-socket=s' => \
$opt_socketfile
36 my $client = IO
::Socket
::UNIX
->new(Peer
=> $opt_socketfile,
41 print "Error connecting to $opt_socketfile: $@\n";
45 my $cmd = shift @ARGV;
47 if (not defined($cmd)) {
48 print "Usage: bitlbee-ctl.pl [options] command ...\n";
53 $client->send("DIE\r\n");
55 print "No such command: $cmd\n";