Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 2e9666521b | |||
| b75ec5aba8 | |||
| 657d5ccd31 | |||
| 5801030e31 | |||
| 8adadb0be1 |
1
.hgtags
1
.hgtags
@@ -3,3 +3,4 @@
|
|||||||
d4733a95c3428db8722ce0d0350d17bbbabc8720 release-r72
|
d4733a95c3428db8722ce0d0350d17bbbabc8720 release-r72
|
||||||
7c92f9e2e4818d74eded59ad516d7d58b4072f8d release-r97
|
7c92f9e2e4818d74eded59ad516d7d58b4072f8d release-r97
|
||||||
b1426986ff5f265f79d6412c0e81ccc7cae652ff release-r118
|
b1426986ff5f265f79d6412c0e81ccc7cae652ff release-r118
|
||||||
|
2b11aaaad98718025d020c9fbaa451f65d413477 release-r126
|
||||||
|
|||||||
@@ -14,6 +14,11 @@ Written in PHP, Bash
|
|||||||
|
|
||||||
=CHANGELOG=
|
=CHANGELOG=
|
||||||
|
|
||||||
|
2017-10-28: v132
|
||||||
|
- Fix an issue with not applying project rename redirections in the new URL format
|
||||||
|
- Fix a cosmetic issue with classifying downloads named with numeric strings
|
||||||
|
- Fix a cosmetic issue with truncated sheilds caused by ID collisions
|
||||||
|
|
||||||
2017-04-23: v126
|
2017-04-23: v126
|
||||||
- Breaking: BASEURL is now a mandatory field
|
- Breaking: BASEURL is now a mandatory field
|
||||||
- Feature: Support `[go-get]` tags
|
- Feature: Support `[go-get]` tags
|
||||||
|
|||||||
@@ -196,7 +196,7 @@ class CProject {
|
|||||||
}
|
}
|
||||||
foreach($this->downloads as $idx => $filename) {
|
foreach($this->downloads as $idx => $filename) {
|
||||||
foreach(array_keys($known_tags) as $tagname) {
|
foreach(array_keys($known_tags) as $tagname) {
|
||||||
if (stripos($filename, $tagname) !== false) {
|
if (stripos($filename, (string)$tagname) !== false) {
|
||||||
$found_idx[$idx] = $tagname;
|
$found_idx[$idx] = $tagname;
|
||||||
|
|
||||||
$render_per_tag[$tagname][$idx] = $filename;
|
$render_per_tag[$tagname][$idx] = $filename;
|
||||||
|
|||||||
@@ -183,7 +183,14 @@ function redirecthtml($target) {
|
|||||||
|
|
||||||
function buildredirects($redirects) {
|
function buildredirects($redirects) {
|
||||||
foreach($redirects as $oldname => $newname) {
|
foreach($redirects as $oldname => $newname) {
|
||||||
$page = redirecthtml($newname.'.html');
|
|
||||||
|
$page = redirecthtml(BASEURL.$newname.'/');
|
||||||
|
|
||||||
|
// old format
|
||||||
file_put_contents(BASEDIR.'wwwroot/'.$oldname.'.html', $page);
|
file_put_contents(BASEDIR.'wwwroot/'.$oldname.'.html', $page);
|
||||||
|
|
||||||
|
// new format
|
||||||
|
mkdir(BASEDIR.'wwwroot/'.$oldname);
|
||||||
|
file_put_contents(BASEDIR.'wwwroot/'.$oldname.'/index.html', $page);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -15,6 +15,12 @@ function mkshield($left_str, $right_str, $color_str) {
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
$retn = file_get_contents('https://img.shields.io/badge/'.$filename);
|
$retn = file_get_contents('https://img.shields.io/badge/'.$filename);
|
||||||
|
|
||||||
|
// We need unique IDs
|
||||||
|
$prefix = substr(sha1($filename), 8).'-';
|
||||||
|
$retn = str_replace('id="', 'id="'.$prefix, $retn);
|
||||||
|
$retn = str_replace('url(#', 'url(#'.$prefix, $retn);
|
||||||
|
|
||||||
file_put_contents($cache_path, $retn);
|
file_put_contents($cache_path, $retn);
|
||||||
return $retn;
|
return $retn;
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user