104 lines
4.1 KiB
Diff
104 lines
4.1 KiB
Diff
Index: collectstats.pl
|
|
===================================================================
|
|
RCS file: /cvsroot/mozilla/webtools/bugzilla/collectstats.pl,v
|
|
retrieving revision 1.71
|
|
diff -u -r1.71 collectstats.pl
|
|
--- collectstats.pl 6 Sep 2009 22:45:51 -0000 1.71
|
|
+++ collectstats.pl 16 May 2010 09:22:28 -0000
|
|
@@ -51,7 +51,7 @@
|
|
|
|
# Tidy up after graphing module
|
|
my $cwd = Cwd::getcwd();
|
|
-if (chdir("graphs")) {
|
|
+if (chdir(bz_locations()->{'graphdir'})) {
|
|
unlink <./*.gif>;
|
|
unlink <./*.png>;
|
|
# chdir("..") doesn't work if graphs is a symlink, see bug 429378
|
|
Index: reports.cgi
|
|
===================================================================
|
|
RCS file: /cvsroot/mozilla/webtools/bugzilla/reports.cgi,v
|
|
retrieving revision 1.95
|
|
diff -u -r1.95 reports.cgi
|
|
--- reports.cgi 24 Oct 2009 05:21:06 -0000 1.95
|
|
+++ reports.cgi 16 May 2010 09:22:28 -0000
|
|
@@ -45,6 +45,8 @@
|
|
use Bugzilla::Error;
|
|
use Bugzilla::Status;
|
|
|
|
+use File::Basename;
|
|
+
|
|
# If we're using bug groups for products, we should apply those restrictions
|
|
# to viewing reports, as well. Time to check the login in that case.
|
|
my $user = Bugzilla->login();
|
|
@@ -54,8 +56,8 @@
|
|
}
|
|
|
|
my $dir = bz_locations()->{'datadir'} . "/mining";
|
|
-my $graph_url = 'graphs';
|
|
-my $graph_dir = bz_locations()->{'libpath'} . '/' .$graph_url;
|
|
+my $graph_dir = bz_locations()->{'graphdir'};
|
|
+my $graph_url = basename($graph_dir);
|
|
|
|
Bugzilla->switch_to_shadow_db();
|
|
|
|
Index: Bugzilla/Constants.pm
|
|
===================================================================
|
|
RCS file: /cvsroot/mozilla/webtools/bugzilla/Bugzilla/Constants.pm,v
|
|
retrieving revision 1.126.2.5
|
|
diff -u -r1.126.2.5 Constants.pm
|
|
--- Bugzilla/Constants.pm 13 Apr 2010 04:56:24 -0000 1.126.2.5
|
|
+++ Bugzilla/Constants.pm 16 May 2010 09:22:29 -0000
|
|
@@ -551,6 +551,7 @@
|
|
# The script should really generate these graphs directly...
|
|
'webdotdir' => "/var/lib/bugzilla/$datadir/webdot",
|
|
'extensionsdir' => "$libpath/extensions",
|
|
+ 'graphdir' => "$libpath/graphs",
|
|
};
|
|
}
|
|
|
|
Index: Bugzilla/Install/Filesystem.pm
|
|
===================================================================
|
|
RCS file: /cvsroot/mozilla/webtools/bugzilla/Bugzilla/Install/Filesystem.pm,v
|
|
retrieving revision 1.47.2.1
|
|
diff -u -r1.47.2.1 Filesystem.pm
|
|
--- Bugzilla/Install/Filesystem.pm 20 Feb 2010 20:20:55 -0000 1.47.2.1
|
|
+++ Bugzilla/Install/Filesystem.pm 16 May 2010 09:22:29 -0000
|
|
@@ -69,6 +69,7 @@
|
|
my $attachdir = bz_locations()->{'attachdir'};
|
|
my $extensionsdir = bz_locations()->{'extensionsdir'};
|
|
my $webdotdir = bz_locations()->{'webdotdir'};
|
|
+ my $graphdir = bz_locations()->{'graphdir'};
|
|
my $templatedir = bz_locations()->{'templatedir'};
|
|
my $libdir = bz_locations()->{'libpath'};
|
|
my $extlib = bz_locations()->{'ext_libpath'};
|
|
@@ -162,7 +163,7 @@
|
|
dirs => $ws_dir_writeable },
|
|
$webdotdir => { files => $ws_writeable,
|
|
dirs => $ws_dir_writeable },
|
|
- graphs => { files => $ws_writeable,
|
|
+ $graphdir => { files => $ws_writeable,
|
|
dirs => $ws_dir_writeable },
|
|
|
|
# Readable directories
|
|
@@ -212,7 +213,7 @@
|
|
"$datadir/extensions" => $ws_dir_readable,
|
|
$attachdir => $ws_dir_writeable,
|
|
$extensionsdir => $ws_dir_readable,
|
|
- graphs => $ws_dir_writeable,
|
|
+ $graphdir => $ws_dir_writeable,
|
|
$webdotdir => $ws_dir_writeable,
|
|
"$skinsdir/custom" => $ws_dir_readable,
|
|
"$skinsdir/contrib" => $ws_dir_readable,
|
|
@@ -342,10 +343,11 @@
|
|
my %files = %{$fs->{create_files}};
|
|
|
|
my $datadir = bz_locations->{'datadir'};
|
|
+ my $graphdir = bz_locations->{'graphdir'};
|
|
# If the graphs/ directory doesn't exist, we're upgrading from
|
|
# a version old enough that we need to update the $datadir/mining
|
|
# format.
|
|
- if (-d "$datadir/mining" && !-d 'graphs') {
|
|
+ if (-d "$datadir/mining" && !-d $graphdir) {
|
|
_update_old_charts($datadir);
|
|
}
|
|
|