#!/usr/local/bin/perl
require('getopts.pl');
#
# CAPA installation script version 1.0
#
# Installation is a multi-phased operation and
# can start in any point
#
# -m [menu mode (interactive mode)]
# -c [install a class]
#
#
sub S_Enterpath {
local($set)=@_;
local($notdone,$path);
$notdone = 1;
while ($notdone) {
print "Please enter the CLASS absolute path:\n";
$path = <>; chomp($path);
if( $path =~ /\/$/ ) {
$Rfullpath = "$path" . "records";
$Lfullpath = "$path" . "records/log$set.db";
$Wfullpath = "$path" . "records/weblog$set.db";
} else {
$Rfullpath = "$path" . "/records";
$Lfullpath = "$path" . "/records/log$set.db";
$Wfullpath = "$path" . "/records/weblog$set.db";
}
if( -d $path ) {
if( -d $Rfullpath ) {
if( -f $Lfullpath ) {
$notdone = 0;
} else {
print "File [$Lfullpath] does not exist!\n";
}
if( -f $Wfullpath ) {
$notdone = 0;
} else {
print "File [$Wfullpath] does not exist!\n";
}
} else {
print "Directory [$Rfullpath] does not exist!\n";
}
} else {
print "Directory [$path] does not exist!\n";
}
}
return ($path);
}
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>