version 1.4, 2006/06/28 20:48:04
|
version 1.6, 2024/07/08 22:06:15
|
Line 1
|
Line 1
|
<!DOCTYPE piml PUBLIC "-//TUX/DTD piml 1.0 Final//EN" |
<!DOCTYPE piml PUBLIC "-//TUX/DTD piml 1.0 Final//EN" |
"http://lpml.sourceforge.net/DTD/piml.dtd"> |
"http://lpml.sourceforge.net/DTD/piml.dtd"> |
<!-- accesscount_seed.piml --> |
<!-- update_queue_slots.piml --> |
<!-- Matthew Hall --> |
<!-- Matthew Hall --> |
|
|
<!-- $Id$ --> |
<!-- $Id$ --> |
Line 132 sub process_gradingqueue_file {
|
Line 132 sub process_gradingqueue_file {
|
|
|
|
|
sub main { |
sub main { |
print("Updating grading queue and slot definitions\n"); |
my $doupdate; |
my $perlvar=LONCAPA::Configuration::read_conf('loncapa.conf'); |
if (-e '/etc/loncapa-release') { |
find( |
if (open(PIPE,"cat /etc/loncapa-release.prev |grep '^LON-CAPA release' |")) { |
{ |
if (<PIPE> =~ /^\QLON-CAPA release \E(CVS_HEAD|\d+\.\d+\.\d+\.?\w*)\-\d+$/) { |
no_chdir => 1, |
my $previous = $1; |
wanted => \&process_gradingqueue_file, |
unless ($previous eq 'CVS_HEAD') { |
}, |
my ($major,$minor) = ($previous =~ /^(\d+)\.(\d+)\./); |
$perlvar->{'lonUsersDir'}); |
if (($major ne '') && ($minor ne '')) { |
print("\n"); |
if (($major == 2) && ($minor < 10)) { |
|
$doupdate = 1; |
|
} |
|
} |
|
} |
|
} |
|
close(PIPE); |
|
} |
|
} |
|
|
|
if ($doupdate) { |
|
print("Updating grading queue and slot definitions\n"); |
|
my $perlvar=LONCAPA::Configuration::read_conf('loncapa.conf'); |
|
find( |
|
{ |
|
no_chdir => 1, |
|
wanted => \&process_gradingqueue_file, |
|
}, |
|
$perlvar->{'lonUsersDir'}); |
|
print("\n"); |
|
} else { |
|
print("Update of grading queue and slot definitions not required.\n"); |
|
} |
} |
} |
|
|
&main(); |
&main(); |