ddoc should generate hyperlinks to source code
Vladimir Panteleev
vladimir at thecybershadow.net
Tue Mar 12 22:56:30 PDT 2013
On Wednesday, 13 March 2013 at 03:47:10 UTC, timotheecour wrote:
> The hyperlink target should be customizable, either a url (eg:
> github, making sure it's retrieving the proper commit id so
> that code is in sync with ddoc), or local file system for users.
In order to link to the local file system, the distribution needs
to contain HTML-rendered source code. There is no convention for
linking to a specific place in a text file.
I think including .html versions of all Phobos source code is not
worth it for the links alone. However, it would be nice if there
was a HTML version of the source code, which contained links to
each identifier's definitions wherever they appear, such as the
LXR project: See e.g.
http://lxr.linux.no/#linux+v3.8.2/kernel/acct.c
For for GitHub links, the makefile could create a .ddoc inclusion
file which defines the URL base (pointing to GitHub, to the
current commit), for the compiler to use when generating the
links in the documentation.
More information about the Digitalmars-d
mailing list