#!/usr/bin/perl

# Config

$cyrus_user = 		'cyrus';
$cyrus_password =	'cyruspass';
$cyrus_host =		'localhost';

# unixhierarchysep => 1 (yes) / 0 (no)
$unixhierarchysep =	1;

# Common routines

sub mailbox_name {
	my $mailbox = shift;
	
	if($unixhierarchysep) {
	        $mailbox = 'user/'.$ARGV[0];
	} else {
        	$mailbox = 'user.'.$ARGV[0];
	}

	return $mailbox;
}

sub die_on_error {
	my $cyradm = shift;
	if($cyradm->error) { die $cyradm->error; }
}
1;

