Ticket #11948: portlivecheck.tcl.diff
File portlivecheck.tcl.diff, 2.0 KB (added by n.oxyde@…, 18 years ago) |
---|
-
portlivecheck.tcl
old new 72 72 73 73 # Determine the default type depending on the mirror. 74 74 if {${livecheck.check} eq "default"} { 75 if {$has_master_sites && [regexp {\y(sourceforge|freshmeat|googlecode )\y(?::(\S+))?} $master_sites _ site tag]} {75 if {$has_master_sites && [regexp {\y(sourceforge|freshmeat|googlecode|gnu)\y(?::(\S+))?} $master_sites _ site tag]} { 76 76 if {$tag ne "" && ${livecheck.name} eq "default"} { 77 77 set livecheck.name $tag 78 78 } … … 80 80 } else { 81 81 set livecheck.check "freshmeat" 82 82 } 83 if {$has_homepage && [regexp {^http://code.google.com/p/([^/]+)} $homepage _ tag]} { 84 if {${livecheck.name} eq "default"} { 85 set livecheck.name $tag 86 } 87 set livecheck.check "googlecode" 88 } 83 if {$has_homepage} { 84 if {[regexp {^http://code.google.com/p/([^/]+)} $homepage _ tag]} { 85 if {${livecheck.name} eq "default"} { 86 set livecheck.name $tag 87 } 88 set livecheck.check "googlecode" 89 } elseif {[regexp {^http://www.gnu.org/software/([^/]+)} $homepage _ tag]} { 90 if {${livecheck.name} eq "default"} { 91 set livecheck.name $tag 92 } 93 set livecheck.check "gnu" 94 } 95 } 89 96 } 90 97 if {${livecheck.name} eq "default"} { 91 98 set livecheck.name $name … … 126 133 } 127 134 set livecheck.check "regex" 128 135 } 136 "gnu" { 137 if {!$has_homepage || ${livecheck.url} eq ${homepage}} { 138 set livecheck.url "http://ftp.gnu.org/gnu/${livecheck.name}/?M=D" 139 } 140 if {${livecheck.distname} eq "default"} { 141 set livecheck.distname ${livecheck.name} 142 } 143 if {${livecheck.regex} eq ""} { 144 set livecheck.regex {${livecheck.distname}-(\\d+(?:\\.\\d+)*)} 145 } 146 set livecheck.check "regex" 147 } 129 148 } 130 149 131 150 switch ${livecheck.check} {