Don't try to change ".md" extension to ".html"

On Gerrit's HttpPluginServlet, we can handle both ".md" and ".html"
extensions just fine with ".md" source files. In the mean time, gitiles
can only handle the actual extensions (".md"). So in order to not break
gitiles, we should encourage plugin developers to use ".md" extension in
the links in their docs, instead of ".html".

But currently in the auto generated "index.html", we list all the ".md"
file in plugin and change their extensions to ".html". This is a bad
example and will actually encourage plugin developers to use ".html"
extension. So let's stop doing that.

Eventually we would want to change all the links in all the plugins'
docs back to ".md" to unbreak gitiles. But that will be in separated
changes.

Change-Id: I056259c148ade92dcd387092665afe81c438ec1d
This commit is contained in:
Yuxuan 'fishy' Wang
2016-08-22 16:56:12 -07:00
parent 7ca92f2916
commit fbc348ee1e

View File

@@ -359,7 +359,6 @@ class HttpPluginServlet extends HttpServlet
if (Strings.isNullOrEmpty(entryTitle)) {
entryTitle = rsrc.substring(nameOffset, rsrc.length() - 3).replace('-', ' ');
}
rsrc = rsrc.substring(0, rsrc.length() - 3) + ".html";
} else {
entryTitle = rsrc.substring(nameOffset).replace('-', ' ');
}