浏览代码

Improve gitlog script to reference Github issues

Yannick Warnier 8 年之前
父节点
当前提交
2f2529fbbe
共有 1 个文件被更改,包括 13 次插入3 次删除
  1. 13 3
      tests/scripts/packaging/gitlog.php

+ 13 - 3
tests/scripts/packaging/gitlog.php

@@ -60,10 +60,20 @@ foreach ($logs as $log) {
         if (substr($issue, 0, 1) == '#') {
             // not a BeezNest task
             $num = substr($issue, 1);
-            if ($formatHTML) {
-                $issueLink = ' - <a href="https://support.chamilo.org/issues/' . $num . '">#' . $num . '</a>';
+            if ($num > 4000) {
+                //should be Chamilo support site
+                if ($formatHTML) {
+                    $issueLink = ' - <a href="https://support.chamilo.org/issues/' . $num . '">CT#' . $num . '</a>';
+                } else {
+                    $issueLink = ' - ' . $num;
+                }
             } else {
-                $issueLink = ' - ' . $num;
+                //should be Github
+                if ($formatHTML) {
+                    $issueLink = ' - <a href="https://github.com/chamilo/chamilo-lms/issues/' . $num . '">GH#' . $num . '</a>';
+                } else {
+                    $issueLink = ' - ' . $num;
+                }
             }
         } else {
             $num = substr($issue, 3);