Changeset 37772 for other-projects


Ignore:
Timestamp:
2023-06-15T20:28:30+12:00 (12 months ago)
Author:
anupama
Message:
  1. Mac Monterey binary is now to be uploaded nightly, replacing (Snow) Leopard and (Mountain) Lion Mac binaries which we don't generate any more. 2. Some cumulative changes since last time, mainly to do with testing variables are set in php, and MacMojave IsisGdl binary, which works for Monterey iff it's pulled in and used for Monterey, as I've now tested the CDS-ISIS tutorial on the Mac Monterey with both regular GLI and WebSwing GLI.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • other-projects/nightly-tasks/crons-and-scripts/caveat-emptor/index.php

    r32968 r37772  
    3131
    3232      //chdir("/greenstone/greenstone.org/base/caveat-emptor");
    33 if ( $_GET['latest'] ) {
     33if ( isset($_GET['latest']) ) {
    3434  chdir("/greenstone/greenstone.org/base/caveat-emptor/latest");
    3535 } else {
     
    4040$todayFiles = array();
    4141
    42 if ( $_GET['offset']) {
     42if ( isset($_GET['offset'])) {
    4343    $todayStart = strtotime(date("Y-m-d",strtotime($_GET['offset'] . " days")));
    4444} else {
     
    4949$today = date("Y.m.d", $todayStart);
    5050$todayWithHyphens = date("Y-m-d", $todayStart);
    51 
    5251$nextRelease2 = trim(file_get_contents("/greenstone/greenstone.org/base/next-release.txt"));
    5352$nextRelease3 = trim(file_get_contents("/greenstone/greenstone.org/base/next-release-greenstone3.txt"));
     
    5655    if ( substr($file,0,1) == "." ) continue;
    5756    if ( $file === "index.php" ) continue;
    58     if ( $_GET['latest'] ) {     
     57    if ( $file === "latest" ) continue;
     58    if ( isset($_GET['latest']) ) {   
    5959      $todayFiles[$file] = true;
    6060      continue;
     
    105105}
    106106
    107 function show( $file, $forceShow, $extra_info, $rename ) {
     107function show( $file, $forceShow = false, $extra_info = NULL, $rename = NULL ) {
    108108    global $todayFiles;
    109109
    110     if ( $_GET['latest'] ) {
     110    if ( isset($_GET['latest']) ) {
    111111      //echo "XXX $file";
    112112
     
    130130
    131131    if ( file_exists($file) || $forceShow ) {
    132       if ( $_GET['latest'] ) {
     132      if ( isset($_GET['latest']) ) {
    133133
    134134        $filepath="latest/".$file;
     
    139139<tr>
    140140        <td><a href="<?php echo $filepath; ?>"><?php if($rename) { echo $rename; } else { echo $file; } ?></a><?php if($extra_info) { echo " - ".$extra_info; } ?></td>
    141     <td><?php echo date("h:ia",filemtime($file)); ?></td>
    142     <td><?php echo formatBytes(filesize($file)); ?></td>
     141    <td><?php if (file_exists($file)) {echo date("h:ia",filemtime($file));} ?></td>
     142    <td><?php if (file_exists($file)) {echo formatBytes(filesize($file));} ?></td>
    143143</tr>
    144144<?php
     
    171171    // in the latest folder, display the bin/src link for any available date
    172172    // (there should only be one)
    173     if($_GET['latest']) {
     173    if(isset($_GET['latest'])) {
    174174      $regex = preg_replace( "/\d{4}.\d{2}\.\d{2}/", "\d{4}.\d{2}.\d{2}", $regex );
    175175    }
     
    186186
    187187//show time machine
    188 if ($_GET['latest'] ) {
     188if (isset($_GET['latest']) ) {
    189189  echo "latest ";
    190190} else {
     
    193193for ( $i=4; $i>=0; $i-- ) {
    194194        $d = date("Y-m-d",strtotime("-$i days"));
    195         if ( $d == $todayWithHyphens && ! $_GET['latest']) {
     195        if ( $d == $todayWithHyphens && ! isset($_GET['latest'])) {
    196196                echo $d;
    197197        } else {
     
    210210show("Greenstone-$nextRelease3-candidate-$today-windows.exe");
    211211showAllMatching("Greenstone-$nextRelease3-candidate-$today-MacOS-intel.dmg", 0, "for (Snow) Leopards (v10.5-10.6)", "Greenstone-$nextRelease3-candidate-$today-Leopard-MacOS-intel.dmg");
    212 show("Greenstone-$nextRelease3-candidate-$today-Lion-MacOS-intel.dmg", 0, "for (Mountain) Lions (v10.7-10.8)");
     212//show("Greenstone-$nextRelease3-candidate-$today-Lion-MacOS-intel.dmg", 0, "for (Mountain) Lions (v10.7-10.8)");
     213show("Greenstone-$nextRelease3-candidate-$today-Monterey-MacOS-intel.dmg", 0, "for Monterey (MacOS v12)");
    213214//this picks up similar releases of other version numbers lying around
    214215showAllMatching("Greenstone-3\..*-candidate-$today-linux$");
    215216showAllMatching("Greenstone-3\..*-candidate-$today-windows.exe$");
    216 showAllMatching("Greenstone-3\..*-candidate-$today-MacOS-intel.dmg$", 0, "for (Snow) Leopards (v10.5-10.6)");
    217 showAllMatching("Greenstone-3\..*-candidate-$today-Lion-MacOS-intel.dmg$", 0, "for (Mountain) Lions (v10.7-10.8)");
     217//showAllMatching("Greenstone-3\..*-candidate-$today-MacOS-intel.dmg$", 0, "for (Snow) Leopards (v10.5-10.6)");
     218//showAllMatching("Greenstone-3\..*-candidate-$today-Lion-MacOS-intel.dmg$", 0, "for (Mountain) Lions (v10.7-10.8)");
     219showAllMatching("Greenstone-3\..*-candidate-$today-Monterey-MacOS-intel.dmg$", 0, "for Monterey (MacOS v12)");
    218220gap();
    219221
     
    230232show("Greenstone-$nextRelease2-candidate-$today-windows.exe");
    231233showAllMatching("Greenstone-$nextRelease2-candidate-$today-MacOS-intel.dmg", 0, "for (Snow) Leopards (v10.5-10.6)","Greenstone-$nextRelease2-candidate-$today-Leopard-MacOS-intel.dmg");
    232 show("Greenstone-$nextRelease2-candidate-$today-Lion-MacOS-intel.dmg", 0, "for (Mountain) Lions (v10.7-10.8)");
     234//show("Greenstone-$nextRelease2-candidate-$today-Lion-MacOS-intel.dmg", 0, "for (Mountain) Lions (v10.7-10.8)");
     235show("Greenstone-$nextRelease2-candidate-$today-Monterey-MacOS-intel.dmg", 0, "for Monterey (MacOS v12)");
    233236
    234237showAllMatching("Greenstone-2\..*-candidate-$today-linux$");
    235238showAllMatching("Greenstone-2\..*-candidate-$today-linux-x64$");
    236239showAllMatching("Greenstone-2\..*-candidate-$today-windows.exe$");
    237 showAllMatching("Greenstone-2\..*-candidate-$today-MacOS-intel.dmg$", 0, "for Snow Leopards (v10.5-10.6)");
    238 showAllMatching("Greenstone-2\..*-candidate-$today-Lion-MacOS-intel.dmg$", 0, "for (Mountain) Lions (v10.7-10.8)");
     240//showAllMatching("Greenstone-2\..*-candidate-$today-MacOS-intel.dmg$", 0, "for Snow Leopards (v10.5-10.6)");
     241//showAllMatching("Greenstone-2\..*-candidate-$today-Lion-MacOS-intel.dmg$", 0, "for (Mountain) Lions (v10.7-10.8)");
     242showAllMatching("Greenstone-2\..*-candidate-$today-Monterey-MacOS-intel.dmg$", 0, "for Monterey (MacOS v12)");
    239243gap();
    240244
     
    247251
    248252heading("Documented Examples" );
    249 show("Greenstone-documented-examples-$today.tar.gz");
    250 show("Greenstone-documented-examples-$today.zip");
    251 gap();
    252 
    253 if ( ! $_GET['latest'] ) {
     253show("Greenstone3-documented-examples-$today.tar.gz");
     254show("Greenstone3-documented-examples-$today.zip");
     255gap();
     256
     257if ( !isset( $_GET['latest']) ) {
    254258  heading("Nightly Build Logs");
    255259  showAllMatching("\.txt$");
     
    266270show("IsisGdl.bin32", 1,"","IsisGdl.linux32"); // temporary
    267271show("IsisGdl.macleopard", 1); // temporary
     272show("IsisGdl.mac64mojave", 1); // temporary
    268273gap();
    269274
Note: See TracChangeset for help on using the changeset viewer.