From 040eeb280297459cdab6c47d6064341fc5875da8 Mon Sep 17 00:00:00 2001 From: Bjørn Lindeijer Date: Sun, 23 Nov 2008 21:38:39 +0100 Subject: Display obsolete files in gray and links to svn Old change that never made it into version control. Will be updating this to git now. --- tools/upalyzer/analyze.php | 23 +++++++++++++++++++---- 1 file changed, 19 insertions(+), 4 deletions(-) (limited to 'tools') diff --git a/tools/upalyzer/analyze.php b/tools/upalyzer/analyze.php index 106fcbb5..3758eae4 100644 --- a/tools/upalyzer/analyze.php +++ b/tools/upalyzer/analyze.php @@ -19,7 +19,7 @@ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */ header("Content-type: text/html"); -header("Cache-Control: no-store, no-cache, must-revalidate"); +header("Cache-Control: no-store, no-cache, must-revalidate"); header("Cache-Control: post-check=0, pre-check=0", false); header("Pragma: no-cache"); @@ -31,6 +31,9 @@ header("Pragma: no-cache"); List of current updates: $update) { - printf("%-{$update_entry_maxlen}s ", $entry); - print_update_name($update, false); + $exists = file_exists($svn_checkout_path . $entry); + printf("%-{$update_entry_maxlen}s ", + $exists ? "black" : "rgb(100,100,100)", + $entry); + print_update_name($update, true); + + if ($exists) { + // Temporary hack to make URLs to map files work + $entry = str_replace('.tmx.gz', '.tmx', $entry); + + printf(' svn', $svn_url_base, $entry); + if (substr($entry, strlen($entry) - 1) != '/') + printf(' download', $download_url_base, $entry); + } echo "\n"; } -- cgit v1.2.3-70-g09d2