-
Notifications
You must be signed in to change notification settings - Fork 3
/
export_problem_libraries_from_cvs.pl
48 lines (41 loc) · 1.33 KB
/
export_problem_libraries_from_cvs.pl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/usr/bin/perl -w
use strict;
##this comment is just a change so I can test pushing to the svn from git
## run this script in a directory that does not contain
## any files whose names end in ".tar.gz" since this
## produces one such file for each module below and then
## at the end
## list the repository name and then the module name
my @repository_module = qw(
rochester rochester_problib
rochester rochester_grade8problems
rochester rochester_physics_problib
asu asu_problib
asu database_problems
dartmouth dartmouth_problib
dcds dcds_problib
indiana indiana_problib
nau nau_problib
ohio-state osu_problib
sunysb sunysb_problib
tcnj tcnj_problib
unh unh_highschool_problib
unh unh_problib
union union_problib
);
my ($repository, $module, @command_args);
my @tar_file_list = ();
while (@repository_module ) {
$repository = shift @repository_module;
$module = shift @repository_module;
mkdir $module;
@command_args = qq(cvs -q -d :ext:apizer\@devel.webwork.rochester.edu:/webwork/cvs/$repository export -D now -d $module $module);
system (@command_args);
push @tar_file_list, "${module}.tar.gz";
@command_args = qq(tar -czf ${module}.tar.gz $module);
system (@command_args);
@command_args = qq(rm -r $module);
system (@command_args);
}
@command_args = qq(tar -czf all_problem_libraries.tar.gz @tar_file_list);
system (@command_args);