diff --git a/src/mako/index.html.mako b/src/mako/index.html.mako
index 9b98515857..cbb9f03d6c 100644
--- a/src/mako/index.html.mako
+++ b/src/mako/index.html.mako
@@ -27,23 +27,11 @@ DO NOT EDIT !
-->
-
-
-
- ${title}
+
+ ${title}
-
${title}
-
-% for an in sorted(api.list.keys()):
- % if an in api.blacklist:
+
+
${title}
+
+
+
+
API Name
+
API Docs
+
CLI Docs
+
Install
+
+
+
+ % for name in sorted(api.list.keys()):
+ % if name in api.blacklist:
<% continue %>\
- % endif
- % for v in api.list[an]:
+ % endif
+ % for version in api.list[name]:
+
<%
- type_names = tc.keys()
- with open(api_json_path(directories.api_base, an, v)) as fp:
- api_data = json.load(fp)
+ type_names = ["api", "cli"]
+ assert set(type_names) == set(tc.keys()), "The type cache has changed, make sure to update the documentation accordingly"
+
+ with open(api_json_path(directories.api_base, name, version)) as fp:
+ metadata = json.load(fp)
+
+ if metadata is None:
+ continue
+
+ api_data = tc["api"]
+ revision = metadata.get('revision', None)
+
+ api_link = api_index(DOC_ROOT, name, version, api_data['make'],
+ api_data['cargo'], revision)
+
+ crates_link = crates_io_url(name, version)
+ crates_link += "/"
+ crates_link += crate_version(api_data.cargo.build_version, revision)
+
+ cli_data = tc["cli"]
+ cli_link = api_index(DOC_ROOT, name, version, cli_data['make'],
+ cli_data['cargo'], revision)
%>\
- % if api_data is None:
- <% continue %>\
- % endif
- ${an} ${v}
- % for program_type in type_names:
- <%
- ad = tc[program_type]
- revision = api_data.get('revision', None)
- %>\
- ${ad.make.id.upper()}
- % if program_type == 'api':
-
- % else:
- ,
- % endif
- % if not loop.last:
-,
- % endif
- % endfor # each program type
-
- % endfor # each version
-% endfor # each API
-
+