[system] / trunk / webwork2 / lib / WeBWorK / CourseEnvironment.pm Repository:
ViewVC logotype

Diff of /trunk/webwork2/lib/WeBWorK/CourseEnvironment.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

Revision 1050 Revision 1051
15use strict; 15use strict;
16use warnings; 16use warnings;
17use Safe; 17use Safe;
18use WeBWorK::Utils qw(readFile); 18use WeBWorK::Utils qw(readFile);
19 19
20# new($invocant, $webworkRoot, $courseName) 20# new($invocant, $webworkRoot, $webworkURLRoot, $pgRoot, $courseName)
21# $invocant implicitly set by caller 21# $invocant implicitly set by caller
22# $webworkRoot directory that contains the WeBWorK distribution 22# $webworkRoot directory that contains the WeBWorK distribution
23# $webworkURLRoot URL that points to the WeBWorK system 23# $webworkURLRoot URL that points to the WeBWorK system
24# $pgRoot directory that contains the PG distribution
24# $courseName name of the course being used 25# $courseName name of the course being used
25sub new { 26sub new {
26 my $invocant = shift; 27 my $invocant = shift;
27 my $class = ref($invocant) || $invocant; 28 my $class = ref($invocant) || $invocant;
28 my $webworkRoot = shift; 29 my $webworkRoot = shift;
29 my $webworkURLRoot = shift; 30 my $webworkURLRoot = shift;
31 my $pgRoot = shift;
30 my $courseName = shift || ""; 32 my $courseName = shift || "";
31 my $safe = Safe->new; 33 my $safe = Safe->new;
32 34
33 # set up some defaults that the environment files will need 35 # set up some defaults that the environment files will need
34 $safe->reval("\$webworkRoot = '$webworkRoot'"); 36 $safe->reval("\$webworkRoot = '$webworkRoot'");
35 $safe->reval("\$webworkURLRoot = '$webworkURLRoot'"); 37 $safe->reval("\$webworkURLRoot = '$webworkURLRoot'");
38 $safe->reval("\$pgRoot = '$pgRoot'");
36 $safe->reval("\$courseName = '$courseName'"); 39 $safe->reval("\$courseName = '$courseName'");
37 40
38 # determine location of globalEnvironmentFile 41 # determine location of globalEnvironmentFile
39 my $globalEnvironmentFile = "$webworkRoot/conf/global.conf"; 42 my $globalEnvironmentFile = "$webworkRoot/conf/global.conf";
40 43

Legend:
Removed from v.1050  
changed lines
  Added in v.1051

aubreyja at gmail dot com
ViewVC Help
Powered by ViewVC 1.0.9