[www-releases] r342630 - index.html: Link to docs and release notes for sub-projects as well

Hans Wennborg via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 20 01:45:33 PDT 2018


Author: hans
Date: Thu Sep 20 01:45:33 2018
New Revision: 342630

URL: http://llvm.org/viewvc/llvm-project?rev=342630&view=rev
Log:
index.html: Link to docs and release notes for sub-projects as well

Modified:
    www-releases/trunk/download.html
    www-releases/trunk/index.html

Modified: www-releases/trunk/download.html
URL: http://llvm.org/viewvc/llvm-project/www-releases/trunk/download.html?rev=342630&r1=342629&r2=342630&view=diff
==============================================================================
--- www-releases/trunk/download.html (original)
+++ www-releases/trunk/download.html Thu Sep 20 01:45:33 2018
@@ -49,6 +49,8 @@ next release.</p>
   <li><a href="7.0.0/tools/clang/docs/index.html">Clang</a> (<a href="7.0.0/tools/clang/docs/ReleaseNotes.html">release notes</a>)</li>
   <li><a href="7.0.0/tools/clang/tools/extra/docs/index.html">clang-tools-extra</a> (<a href="7.0.0/tools/clang/tools/extra/docs/ReleaseNotes.html">release notes</a>)</li>
   <li><a href="7.0.0/tools/lld/docs/index.html">LLD</a> (<a href="7.0.0/tools/lld/docs/ReleaseNotes.html">release notes</a>)</li>
+  <li><a href="7.0.0/projects/libcxx/docs/index.html">libc++</a></li>
+  <li><a href="7.0.0/tools/polly/docs/index.html">Polly</a></li>
   <li><a href="7.0.0/llvm_doxygen-7.0.0.tar.xz">LLVM Doxygen</a> (.tar.xz)</li>
   <li><a href="7.0.0/clang_doxygen-7.0.0.tar.xz">Clang Doxygen</a> (.tar.xz)</li>
   <li><a href="7.0.0/clang-tools-extra_doxygen-7.0.0.tar.xz">clang-tools-extra Doxygen</a> (.tar.xz)</li>

Modified: www-releases/trunk/index.html
URL: http://llvm.org/viewvc/llvm-project/www-releases/trunk/index.html?rev=342630&r1=342629&r2=342630&view=diff
==============================================================================
--- www-releases/trunk/index.html (original)
+++ www-releases/trunk/index.html Thu Sep 20 01:45:33 2018
@@ -61,8 +61,20 @@ source download and online.</p>
 
 <script type="text/javascript">
 function addReleases() {
+
+  // Mapping from project name to docs dir.
+  var DOCSDIR = {
+    'llvm':         'docs',
+    'clang':        'tools/clang/docs',
+    'clang-extra':  'tools/clang/tools/extra/docs',
+    'lld':          'tools/lld/docs',
+    'libc++':       'projects/libcxx/docs',
+    'polly':        'tools/polly/docs'
+  };
+
+  // date, version, [releasenotes, docs].
   var RELEASES = [
-    ['19 Sep 2018', '7.0.0'],
+    ['19 Sep 2018', '7.0.0', ['llvm', 'clang', 'lld', 'clang-extra'], ['llvm', 'clang', 'lld', 'clang-extra', 'libc++', 'polly']],
     ['5 Jul 2018',  '6.0.1'],
     ['16 May 2018', '5.0.2'],
     ['8 Mar 2018',  '6.0.0'],
@@ -126,8 +138,21 @@ function addReleases() {
     row.appendChild(createCell(date, 'right'));
     row.appendChild(createCell(version));
     row.appendChild(createCell('<a href="download.html#' + version + '">download<\/a>'));
-    row.appendChild(createCell('<a href="' + version + '/docs/ReleaseNotes.html">release notes<\/a>'));
-    row.appendChild(createCell('<a href="' + version + '/docs/index.html">docs<\/a>'));
+
+    if (RELEASES[i].length >= 3) {
+      // Link to sub-project release notes.
+      row.appendChild(createCell(RELEASES[i][2].map(function(p) { return '<a href="' + version + '/' + DOCSDIR[p] + '/ReleaseNotes.html">' + p + '<\/a>' }).join(' ')));
+    } else {
+      row.appendChild(createCell('<a href="' + version + '/docs/ReleaseNotes.html">release notes<\/a>'));
+    }
+
+    if (RELEASES[i].length >= 4) {
+      // Link to sub-project docs.
+      row.appendChild(createCell(RELEASES[i][3].map(function(p) { return '<a href="' + version + '/' + DOCSDIR[p] + '/index.html">' + p + '<\/a>' }).join(' ')));
+    } else {
+      row.appendChild(createCell('<a href="' + version + '/docs/index.html">docs<\/a>'));
+    }
+
   }
 }
 addReleases();




More information about the llvm-commits mailing list